Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
BIG PROBLEM - How Do I Do This?
Message
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Miscellaneous
Thread ID:
00829577
Message ID:
00830325
Views:
20
Did a little digging

here's the code

SET LIBRARY TO SYS(2004)+"foxtools.fll" ADDITIVE
* FindWindow() takes two parameters and returns the handle of the
* window, HWND, if it was found.
GetWind = RegFn("FindWindow", "CC", "I")
*Set the first parameter of the call to getwind to 0, null.
wclass=0
winname="My Application"
apphand=CallFn(GetWind,wclass ,winname)
*If the call was successful, stop processing.
IF apphand<>0
WAIT WINDOW ;
"You cannot start another instance of the window 'My Application'!"
QUIT
ENDIF
MODIFY WINDOW screen TITLE "My Application"
WAIT WINDOW ;
"The first instance of the window 'My Application' is running."


Also, unfortunately there wont be a VFP8 or 9 Enterprise book. I dont have
the time to write for the VFP book market anymore.

Thanks
Rodman
Rod Paddock
Editor in Chief CoDe Magazine
President Dash Point Software, Inc.
VP Red Matrix Technologies,Inc.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform