Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Implementing a .net class
Message
 
To
01/05/2005 15:52:18
General information
Forum:
Visual FoxPro
Category:
Visual FoxPro and .NET
Environment versions
Visual FoxPro:
VFP 7
OS:
Windows XP SP2
Miscellaneous
Thread ID:
01009535
Message ID:
01010051
Views:
20
How are you running that .NET form? On another new thread? If so VFP requires that any secondary threads are shutdown bfore it ends or it will throw an exception...

Other environments like VB don't do this - they often hang invisibly instead or wait until completion.

+++ Rick ---

>Rick,
>Thanks for the info. I understand the implementation of the delegate and its interface and I can make this work fine. My original question was asking whether you can successfully do this using VFP7. From what I can see, it cannot. For some reason VFP7 wont' build the application. It can't find the .net type library for some reason. VFP8 an VFP9 seem to handle it ok and I can build my simple app and see it respond to my .net events, no problem.
>
>Now I seem to have another issue. Upon exiting this foxpro app, I get a windows error in the mscorwks.dll. This is a .Net dll I believe. If I run the fox app through the fox debugger, everything runs clean and all apps exist fine. When I run the foxpro app as an exe, I get this weird error after the app exits.
>
>This is essentially what the apps do: The foxpro app has one screen and 1 button. The fox button launches a .net form from the .net dll and instantiates a simple custom fox class to wait for a .net event. Upon closing the .net form that is now visible, an event is fired that the fox app responds to . It responds fine. Now upon closing the .net form and then the fox app, a windows error is thrown in mscorwks.dll.
>Weird.
>
>I can create a small VB6 dll as the event raiser between the .net dll and foxpro and everything runs clean. It seems as soon as I implement the fox class that uses the .net dll, I'll get this windows error.
>
>Any ideas?
+++ Rick ---

West Wind Technologies
Maui, Hawaii

west-wind.com/
West Wind Message Board
Rick's Web Log
Markdown Monster
---
Making waves on the Web

Where do you want to surf today?
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform