Limit Database records for trial demo... or 30 days max

Hello Everyone…

Is there a way to Limit the amount of database records for a user trial demo… eg: 25… total…
or the amount of days that the app will run… (eg: 30 days or less) or some way to let the user use the app to test it… and no longer work after the records or days have elapsed…

PWA… https://app.detek3000.com.poddleytaleseuro.co.uk/
to give you what I mean…

Lyn…

Time based … when the user signs up, set a field on the user with date + 30 days.

On the login button, redirect to a “hey your trial has run out” on the login action when today > expiry date.

Limit based … on your main “add” function, only display the button if the count < 25. Otherwise show a message to say you need to pay.

1 Like

Hello Nigel…

That sounds like the way to do it… I will have a go and try it out…

Very good explanation for this… it must be… if I can follow it!..

Lyn…

1 Like

Hello Nigel…

Thought I could do this easily… Not a Hope!.. I have tried but as simple as you say it… No I can’t do it…

1).“Time based … when the user signs up, set a field on the user with date + 30 days.”
(where do I put the field… add it to users database… show it/add it… on the signup list… do I call the field name “Date” or “Date + 30 Days” in user database… is the date visible in the signup list)

2). I have made a new screen for the redirect should it work…

3). I have added “hey your trial has run out” is it on the “Submit” login button… advanced bit…

4). Do you mean the Login Screen itself… or the Login Submit Button… for your next section …
“on the login action when today > expiry date.” when I make a new action there is no where this shows up… is it a “Custom Action… or Notification” …

So… if you have the time let me know how I can do this… it is vital to all my apps that there is a free trial period… I never have any trouble in the years I worked in Delphi/Rad but this is a pain…

Lyn…

When you make an action, click advanced and you can choose ‘when does this happen’.

You will make it so it happens if TrialExpiry - > is before - > current time.

Hello… Thank’s for your help…

I have done all this… But when you are able to do this… it is easy and done in seconds…

For Aldo Begginers not possible…

1). What is “Trial Expiry”
2). Where is “Current time” is it in database as “Date”… or “Data and Time”…
3). Is the “Current time”.on the login list along with “email… password… and name”…

you see its not just that simple…

Lyn…

  1. you will make this property on the database under the user collection.
  2. not in the database.
    date and time > current time
  3. when they create an account (sign up button) set an action to update user. Update ‘TrialExpiry’ (the property you’ve created on database) to be- current time+30

So when a user hits sign up he’s getting set an expiry date property on database that’s in 30 days time.

1 Like

Thank you adaloguy…

At last something I can make a start with… Good precise advice…
I will let you know how I get on …

Lyn…

Hello…

Done all that you say… and I can see that it would work…
However… I can’t wait that length of time to test it…

I have had a go at setting it for 5 mins from now… but no good… I think because when the app was created 3 weeks ago… it will have that date in it… and I have run out of other emails to try it out as new user sign up…
Unless you know of an “Overide” sign up that I can test if it works…

or another way round it to test it in a few mins of activation…

Lyn…

Use fake emails it doesn’t check. I make up random stuff

1 Like

Also you could delete the old users on the database and make new accounts

1 Like

Thank’s Why didn’t I think of that… its likely down to all the 25 years working in Delphi…
can’t cheat there!..

Lyn

1 Like

I will do that as well…

Lyn…