In a form, I have a CommandButton which I would like to load a class form from a DLL when I click on it.
My DLL has been defined in Visual FoxPro. It has been registered in the registry. From the Visual Basic Project references, I have check the Visual FoxPro DLL which now appears. In the Click() event of the Command Button, I tried to DIM a property to hold a reference to my class form from the DLL. However, at runtime, it always say that the type of the DIM property is Nothing.
Here is the code from the Click() event of the CommandButton.
Private Sub Command1_Click()
Dim MyProperty As MyFormClass
lnResponse = MsgBox(TypeName(MyProperty))
End Sub
The message box always show Nothing as the type.
MyFormClass is a form class from my Visual FoxPro DLL.
What am I missing?