Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I create a time expired login

Status
Not open for further replies.

dmurnane

Technical User
Jul 9, 2007
7
IE
I have several clients with whom I have annual contracts. I give them a database which they have to login to use. I want to be able to put a time limit on their ability to login. In other words if their contract expired at the end of July and they decided not to renew, then after 1 month their login would be de-activated. I am using FM 8.5 advanced. I tried the following script but it immedietly de-activates them. I have tried changing the date format mm/dd/yyyy but still the same result. Can you advise? Many thanks,
Dominic

If [(Get CurrentDate) > 01/09/2009
Go to Layout ["Startup" (Assets)]
Show/Hide Status Area [Hide]
Beep
Show Custom Dialog ["Database Maintenance Alert"; "Please contact Compass - 087-xxx if you are seeing this message as your user licence may have expired."]
Enable Account [Account Name: "Me"; Deactivate]
Re-Login[ ]
End If
 
Short and quick.

>>I give them a database....

Put in that database a timelimit date, together with the current date, nearly hardcoded.

Let your upstartscript check for the first launch of the DB by the client, store that value together with the systemdate, which must be greater than your 'current date' initially put into the db.
This way you can detect if they play with the systemdate.

Make a check to see if the currentsystemdate is greater than the timelimitdate.
Show message for both cases.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top