नोट
इस पृष्ठ तक पहुंच के लिए प्राधिकरण की आवश्यकता होती है। आप साइन इन करने या निर्देशिकाएँ बदलने का प्रयास कर सकते हैं।
इस पृष्ठ तक पहुंच के लिए प्राधिकरण की आवश्यकता होती है। आप निर्देशिकाएँ बदलने का प्रयास कर सकते हैं।
'class' : invalid assembly access specifier - only 'public' or 'private' are allowed
Remarks
When applied to a managed class or struct, the public and private keywords indicate whether the class will be exposed through assembly metadata. Only public or private can be applied to a class in a program compiled with /clr.
The ref and value keywords, when used with /clr, indicate that a class is managed (see Classes and Structs).
Example
The following example generates C3380:
// C3380_2.cpp
// compile with: /clr
protected ref class A { // C3380
// try the following line instead
// ref class A {
public:
static int i = 9;
};
int main() {
A^ myA = gcnew A;
System::Console::WriteLine(myA->i);
}