Compiler Error C2777
TOC
Collapse the table of content
Expand the table of content
This documentation is archived and is not being maintained.

Compiler Error C2777

only one 'put' method can be specified per property

A property (C++) declspec modifier had more than one put property.

The following sample generates C2777:

// C2777.cpp
struct A {
   __declspec(property(put=PutProp,put=PutPropToo))   // C2777
   // try the following line instead
   // __declspec(property(put=PutProp))
      int prop;
   int PutProp(void);
   int PutPropToo(void);
};
Show:
© 2016 Microsoft