Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Need an idea
Message
From
26/09/2000 22:54:50
Charlie Schreiner
Myers and Stauffer Consulting
Topeka, Kansas, United States
 
 
To
26/09/2000 16:32:44
General information
Forum:
Visual FoxPro
Category:
Other
Title:
Miscellaneous
Thread ID:
00421193
Message ID:
00421278
Views:
18
Hi Joe,
I think you should use record or file locks. Another user should only be able to access the app when a lock can be obtained. If a unintended event occurs, the lock is still released. It seems to me you are doing manually what record and file locks to automatically. When my app wants to do a "closing" I can see who is loggin in, not because a name is written to a record, but because the record is locked. Each user has a record and locks it during use of the app.
SCAN FOR NOT RLOCK()
? User + "is still logged in."
ENDSCAN
is the type of logic.
If I FLOCK() the user file, you know loggin is prohibited.

>Hi All! I have a Retail App. that performs daily closing tasks everyday. The app is used as a Standalone at some locations and as a File Server at other locations. I have logic that disables other users from logging into the app. during the daily closing process. I simply log the current posting date to a control record at the beginning of the closing process and then clear it at the end. My only concern is if the user is in the middle of closing and there pc looses power or freezes up the user will not be able to log back into the system because of the flag in the control record.
>
>When I check for this flag I do not know the users id because I'm doing this check as soon as they double click on the icon to run the app. I don't want them to have to enter there userid and pw and then get notified that they can't login right now because closing is in progress.
>
>I want to establish another flag in the control record that uniquely defines that user's pc. So if the user who was performing the daily closing trys to log back in it will let them because of this unique flag. At the end of the closing process I would clear both these flags.
>
>Question is, is there a Windows95 or SYS variable that is unique to the pc itself that I could use?
>
>Hope you can help. Thanks!
>
>Joe
Charlie
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform