Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Detect switching between vfp-app and other applications
Message
From
11/02/2002 08:54:19
 
 
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00618245
Message ID:
00618268
Views:
8
This message has been marked as a message which has helped to the initial question of the thread.
Hi!

You can detect if VFP application is still active only by using the Windows API functions that query if main VFP application window is still active. To trigger the code when switching occurs, make a timer class and put it on the scren at start of the application. In its timer event check constantly with some period (200 miliseconds is enough) if application is still active. If activity changes - trigger the code (to see if changed, you will need to store previous state in some variable or property).

HTH.

>The Activate() and Deactivate() methods don't (seem to) work when switching between the vfp-application and other applications. I want to do a certain action when the user clicks outside my app, and I want to do another action when the user re-enters my app.
>Who has the golden advice? I will certainly give points!
Vlad Grynchyshyn, Project Manager, MCP
vgryn@yahoo.com
ICQ #10709245
The professional level of programmer could be determined by level of stupidity of his/her bugs

It is not appropriate to say that question is "foolish". There could be only foolish answers. Everybody passed period of time when knows nothing about something.
Previous
Reply
Map
View

Click here to load this message in the networking platform