Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Running only one instance of an application
Message
From
23/05/1998 09:56:05
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
 
To
22/05/1998 11:10:31
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00101181
Message ID:
00101394
Views:
26
>Could someone please explain to me the process of restricting the user to running only one instance of an application. By this I mean that once an application is running if they minimize the app. and then try to start another instance of the app. the same minimized app. will maximum. Thus, only one instance of the app. will always be running.
>
>Thanks

This was here already, few months ago:

Set Reso Off
Resource_lc=Set("Reso",1)
ItsOK_ll=.t.
on error ItsOK_ll=.f.
use (resource_lc) again
use
if not(ItsOK_ll)
=messagebox("This app is already in use, please Alt+Tab to find it")
Quit
endif
Set Reso on

You may use the API to automatically find the app and activate it, so the user doesn't have to "Alt+Tab to find it" - see George's approach for that.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform