| Author: Kundan Kumar Sinha 02 Sep 2008 | Member Level: Gold | Rating: Points: 3 |
Hi,
You can do the following thing.
On the launch of application search for one log file at some specific location. It will not exist if the application is launched for first time. So create the file and write some value, like "a" in the file.
When the application opened next file search for the file, it will be existing, raed the value. If it is "a" then change it with "b", and if it is "b" then change it with "c".
If it is "c" then close the application.
Regards, Kundan
|
| Author: ashok 02 Sep 2008 | Member Level: Bronze | Rating: Points: 2 |
thanQ kundan,
am trying the same with having a text file but it has got no security we can edit the text file thats problem.
Ashok
|
| Author: Gajendra 04 Sep 2008 | Member Level: Bronze | Rating: Points: 3 |
Ashok, U mean at any point of time there could not be more than 3 instances running in the machine right. If this is your requirement we can control like this. At starting of application set one value 1 in DB table, next starting of app check the attribute value if it is less than 3 allow application start. On application close decrement the attribute vlue in DB.
Gajendra
|