Jump to content

This topic is 1815 days old. Please don't post here. Open a new topic instead.

Recommended Posts

I have an application, already developed and now I would like to create a Demo Version, based on the quantity of time the software has been opened.

For e.g., if a person has opened the Trial Version after 30 times, he will be informed by a dialogue message telling him that "the evaluation copy has expired".

If anyone can guide/help me on this stat up script, I would really appreciate.

 

Link to post
Share on other sites

You could do something like this:

# First time log in as Demo

If [ not RESOURCE::Demo_flag ]

Set Field [ RESOURCE::Demo_flag ; 1 ]

Set Field [ RESOURCE::Demo_End_TimeStamp ; Get ( CurrentTimeStamp ) + 864000 ] // 10 days for example

Show Custom Dialog [ "Welcome to My Program" ] ;

"You have 10 days to use this Demo. Enjoy exploring."

 

Else If [ Get ( CurrentTimeStamp ) >= RESOURCE::Demo_End_TimeStamp ]

Show Custom Dialog [ "GAME OVER" ;

"The Demo time has expired. Be a part of Changing the world by purchasing My Program Today...."

If [ Get ( LastMessageChoice ) = 1 ]

Open URL [ "http://mywebdomain.com/PurchaseMySoftwarePage" ]

Perform Script [ "Re-Register License" ; Parameter: 1 ]

Else

Close File [ Current File ]

End If

 

# Alert Every time log in if 7 days or less to end of DEMO

Else If [ RESOURCE::Demo_End_TimeStamp - Get ( CurrentTimeStamp ) <= Get ( CurrentTimeStamp ) ≤ 604800

Show Custom Dialog [ "Alert" ;

"You have only "  &
 
Round ( GetAsNumber ( RES_RESOURCE::Demo_End_TimeStamp - Get ( CurrentTimestamp ) ) / 86400 ; 0 ) & 

" Days remaining on this Demo." & ¶ & "Are you ready to change the world with My Software?" & ¶ & 
"Yes, will cancel the demo and allow you to enter a full registration key from a purchase or subscription on our site."

If [ Get ( LastMessageChoice ) = 1 ]

Open URL [ "http://mywebdomain.com/PurchaseMySoftwarePage" ]

Perform Script [ "Re-Register License" ; Parameter: 1 ]

End If

End If

 

You can have other scripts checking if this is a Demo to disable certain features, etc., A  reset Demo Script for you as the developer and so on.

 

Cheers,

Ben

Link to post
Share on other sites

This topic is 1815 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.