The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

Compiler Error C3814


'class member' : this member cannot co-exist with a property of the same name

A property and another class member have the same identifier. To fix this error, change one of the identifiers.

C3814 is only reachable using /clr:oldSyntax.

The following sample generates C3814:

// C3814.cpp
// compile with: /clr:oldSyntax
#using <mscorlib.dll>
using namespace System;

__gc class CMyClass {
   char Size;
   __property int get_Size() {return __Size;}   // C3814
   __property void set_Size(int value) {__Size=value;}   // C3814
   int __Size;

int main() {