Compiler Error C3250 (Windows CE 5.0)

Send Feedback

'class' : invalid base class for valueclass 'class'

A value class can only inherit from an interface or from Microsoft.Runtime.Object; any other base class is illegal.

For example, the following example generates C3250:

valueclass VC1 {
int i;
};

valueclass VC2 : public VC1 {   // C3250; VC1 not an interface of Object
int j;
};

If the intent is for VC2 to contain an instance of VC1, declare VC1 as a member:

valueclass VC2 {
VC1 m_vc1;
int j;
};

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.