G
Guest
I have a class exported in a dll that has member variables I wish to access. When I do it I get an error C2039: 'myVar' : is not a member of myClass
Here is an example of what my code looks like
In the library
__gc class MyClass
public
int myVar
In the application project
#using "MyLibrary.Dll
void main()
int i
MyClass* myObject = new MyClass
i = myObject->myVar; /* error C2039 *
Console::WriteLine("{0}", __box(i))
Any idea how to get this to work? I don't want to use properties as it will break a lot of other code.
Here is an example of what my code looks like
In the library
__gc class MyClass
public
int myVar
In the application project
#using "MyLibrary.Dll
void main()
int i
MyClass* myObject = new MyClass
i = myObject->myVar; /* error C2039 *
Console::WriteLine("{0}", __box(i))
Any idea how to get this to work? I don't want to use properties as it will break a lot of other code.