Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Com Interop Conditional Implements Statement
Message
 
To
11/06/2011 13:20:37
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
MS SQL Server
Application:
Desktop
Miscellaneous
Thread ID:
01513528
Message ID:
01514145
Views:
57
>If it weren't for firing events we could do that, but while I can call methods and pass info to the .net dll, I can only hook up events and fire the dot net events in the vfp app if the class is defined in the main.prg. Tested with an external .fxp or event a class file that is included in the project and it is unreliable firing events.

It shouldn't have anything to do with where the class is instantiated. The key is that the instance you're binding the events to needs to be available and stay available which means it needs to be tied to some global context. Most likely a PUBLIC var or a top level object property on an object that sticks around for the lifetime of the app (or the required event handler).

+++ Rick ---
+++ 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
Reply
Map
View

Click here to load this message in the networking platform