General information
Category:
Visual FoxPro and .NET
Rick,
Don't know if you are still reading these or not, but here goes:
I have followed your web example to a 'T', and have noted a few things. Foxpro is responding to the .Net event just fine from what I can see. I can see another thread being created and removed upon exit of the .net form. However, I am still getting the c000005 error when exiting the small foxpro app in both VFP7 and VFP9. Of course everything runs just as expected inside the foxpro IDE. However, as soon as I get outside the IDE and the program runs the eventhandler class, the foxpro exe will error on exit. Here's the fox code for the eventhandler:
oEvents = NEWOBJECT("myclass")
zz = EVENTHANDLER(frmShell, oEvents)
RETURN
DEFINE CLASS myclass AS session OLEPUBLIC
IMPLEMENTS IJEEvents IN "c:\documents and settings\thompssj\my documents\visual studio projects\testfoxclass2\bin\testfoxclass2.tlb"
PROCEDURE IJEEvents_ShellClosed() AS VOID
* add user code here
ENDPROC
PROCEDURE IJEEvents_ButtonClicked() AS VOID
MESSAGEBOX(".net form button clicked")
ENDPROC
ENDDEFINE
This is pretty much standard example code right from Help. Again it works fine, the event is triggered, but exiting the foxpro exe in windows causes an error. Tried it on a couple of different machines even.
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only