Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Reopen application when minimized
Message
 
To
26/04/2006 10:18:57
Mark Phillips
Erw Custom Programming Inc.
Waterford, Michigan, United States
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP
Network:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01116657
Message ID:
01116671
Views:
19
This message has been marked as the solution to the initial question of the thread.
You need to check if the application is already running before
launching it again, one easy way to do it; but not the best; is to check
for the window title of you application with this code:

LOCAL lnWindowHandle

DECLARE INTEGER FindWindow IN WIN32API INTEGER,STRING
DECLARE INTEGER BringWindowToTop IN WIN32API INTEGER

lnWindowHandle = FindWindow(0,lcMyWindowTitle)

IF lnWwindowHandle > 0 && App is runing bring it forward
=BringWindowToTop(lnWindowHandle)
ENDIF

HTH


>Need help or direction,
>
>I have a small application (vfo8 exe) that runs in a small form on the desktop. If I have the app minimized, and try to reopen it (from my desktop icon) I get an error. Other application I have used (word an so on, will reopen the minimized version when you click on the icon if a version is active.
>
>Is there a way to do this in a fox application?
>
>Thank you very much.
>
>Mark
Luis Guzman, MCP
"The only glory most of us have to hope for
is the glory of being normal." Katherine Fulleton Gerould
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform