June 9, 200916 yr Newbies 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
June 9, 200916 yr You cannot use 01/09/2009 as a date. You must use: Date (09 ; 01 ; 2009) Please see the syntax for the Date function in the calculation dialog as the ";" delimiter may be "," on your system.
June 9, 200916 yr It is not a good idea to hard code your dates. I would have a expire date, and then use that in the If Statement. If [ Get ( CurrentDate ) > ExpiredDate + 30 ] Lee
June 9, 200916 yr You surely have a customer table. Link a subscription table to it. Here's a simple structure customers (pkCustomerID, ...) subscriptions (pkSubscriptionId, fkCustomerID, dateStart, dateEnd, active, ...) Do a login script. Check if the customer has a valid subscription, if not send a message and deactivate the accound.
Create an account or sign in to comment