Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Multiple Fox Programs open...but
Message
From
12/06/2001 17:04:01
N. Lea
Nic Cross Enterprises
Valencia, California, United States
 
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00518551
Message ID:
00518620
Views:
17
This is the code that I am using, and all the title captions are different.

*!* DECLARE INTEGER CreateEvent IN WIN32API ;
*!* INTEGER lpEventAttributes, ;
*!* SHORT bManualReset, ;
*!* SHORT bInitialState, ;
*!* STRING @ lpName
*!* DECLARE INTEGER GetLastError IN Win32API
*!* DECLARE CloseHandle IN Win32API INTEGER hObject
*!* nEh = CreateEvent(0,0,1, PROGRAM(0) + '.EVENT')

*!* IF GetLastError() = 183 OR nEh = 0
*!* *-- This shows that office is currently running in the background.
*!* = MESSAGEBOX('This application is currently running!' + CHR(13) + "You can't open it more than once", 16, '')
*!* =CloseHandle(nEh)
*!* QUIT
*!* ENDIF
*!* ENDIF
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform