code for writing software Evaluation

I need to provide restirction on my vb software package which would give exprity alert after 30 days(from the date of installation).I need to restrict the access of software even if the user changes the system date.
samidhaAsked:
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

x
 
jmwheelerConnect With a Mentor Commented:
The best way that I can think of is to use the registry.  Have your program check for 2 values in the registry every time it starts.  One value will be the date the program is first run the other will be any value you choose to signify the program is expired.  If Value1(Date) is not present then the program needs to put todays date into the registry entry (this should only happen the first time the program is run).  Then if Value2(your choice) is empty and it is not 30 days from Value1 then start the program and leave Value2 empty.  If Value2 is empty and it is after 30 days from Value1 then set Value2 to some value and exit the program.  If Value2 is not empty then exit the program.  

The example above will allow you to set a value in the registry to render the program expired and that value will not be changed regardless of whether the user changes the date back or not.  It will not guard against the user changing the date back before the program expires though.  I don't know how you would accomplish that.  You could pull the date off of a website but that would mean the user of the program would have to have internet access.
0
 
DhaestCommented:
My recommandation: split points between JmWheeler & Dhaest
0
All Courses

From novice to tech pro — start learning today.