|
-
Jun 28th, 2005, 09:10 PM
#1
Thread Starter
Addicted Member
Expiry date for demo product
Hi,
I want to give a demo version of my product to the user, which should be expired after 2 months from the date of installation. Without comapring the system date, how can I do this? any idea??
( I beleive the system date is changebale, so if the user change the system date, my product will not get crash after 2 months !! am i right???)
Thanks..
Think Before Ink
Visual Studio .NET 2002/.NET Framework 1.0
-
Jul 11th, 2005, 01:24 AM
#2
Thread Starter
Addicted Member
Re: Expiry date for demo product
Hi
I Posted this thread, long back. There is no reply. Pls try to help me on this....
Think Before Ink
Visual Studio .NET 2002/.NET Framework 1.0
-
Jul 11th, 2005, 01:50 AM
#3
Re: Expiry date for demo product
You would need to limit the number of uses as well as the time. That way, even if they keep putting their clock back the demo will still expire. You might want to hide a reference to the number of uses in the Registry, perhaps encrypted, to make it difficult to tamper with. There are products available that will handle this stuff for you. They have various levels of cost and functionality.
-
Jul 11th, 2005, 03:53 AM
#4
Thread Starter
Addicted Member
Re: Expiry date for demo product
So, what u mean is , I need to put a counter for the no. of time, the user using the product....Isn't it?
Think Before Ink
Visual Studio .NET 2002/.NET Framework 1.0
-
Jul 11th, 2005, 03:55 AM
#5
Re: Expiry date for demo product
That's correct. I've encountered a great number of demos that do just that.
-
Jul 11th, 2005, 04:10 AM
#6
Thread Starter
Addicted Member
Re: Expiry date for demo product
Think Before Ink
Visual Studio .NET 2002/.NET Framework 1.0
-
Aug 24th, 2005, 06:43 AM
#7
Re: Expiry date for demo product
 Originally Posted by jmcilhinney
That's correct. I've encountered a great number of demos that do just that.
Got any product names or links?
-
Aug 24th, 2005, 07:02 AM
#8
Fanatic Member
Re: Expiry date for demo product
 Originally Posted by mendhak
Got any product names or links?
I wonder how you could have never seen a demo project at all.
just go to adobe.com,macromedia.com or sony.com.
Download any of their trial softwares.They only work for a certain number of times/certain number of days.
C'mon,this is so silly,i know...but,what you asked sounds like this is what you asked...or am i misunderstanding your question?
Godwin
Help someone else with what someone helped you! 
-
Aug 24th, 2005, 07:09 AM
#9
Re: Expiry date for demo product
You're misunderstanding the question. 
I'm looking to implement that functionality in a program, not see it in action.
-
Aug 24th, 2005, 08:08 AM
#10
Fanatic Member
Re: Expiry date for demo product
ok,here,I just quickly made up a small program to show you.. ..Here,Im storing onto a file everytime the program loads.In this example,the program is allowed to run only 3 times.Its checking if the program is run more than 3 times.If it exceeds 3 times,then,the trial period ends.Well,yes,Its easy to crack it,but,only if they knew the file where im storing on and stuff. I guess almost all softwares today are cracked that ways.
VB Code:
Dim filenumber As Integer
Dim times_used As Integer = 1
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
filenumber = FreeFile()
If IO.File.Exists(Application.StartupPath & "\check.myext") Then
FileOpen(filenumber, Application.StartupPath & "\check.myext", OpenMode.Random, OpenAccess.ReadWrite)
FileGet(filenumber, times_used)
MsgBox("You have executed this software " & (times_used) & " times")
FileClose(filenumber)
If times_used >= 3 Then
MsgBox("Sorry,Your trial period is over!!")
Application.Exit()
End If
times_used = times_used + 1
FileOpen(filenumber, Application.StartupPath & "\check.myext", OpenMode.Random, OpenAccess.ReadWrite)
FilePut(filenumber, times_used)
Else
FileOpen(filenumber, Application.StartupPath & "\check.myext", OpenMode.Random, OpenAccess.ReadWrite)
FilePut(filenumber, times_used)
End If
End Sub
If this is really that helpful,please tell me so that Ill put a copy in that forum where they submit code Thanks..oh yeah,i wont forget the comments too if im putting there 
Hope this helps...
Last edited by uniquegodwin; Aug 24th, 2005 at 08:18 AM.
Godwin
Help someone else with what someone helped you! 
-
Aug 24th, 2005, 08:26 AM
#11
Fanatic Member
-
Aug 24th, 2005, 09:42 AM
#12
Fanatic Member
Re: Expiry date for demo product
Heres my ugly commented neat proggy : Made it a function and easier to read and use
VB Code:
Dim filenumber As Integer 'This is a variable were delcaring to get in the value of freefile function.It assigns automatically the value which represents the file
Dim times_used As Integer = 1 'here,our program sets how many times used so far..were initializing it here
Dim max_limit As Integer = 5 'Set the maximum number of times he can use here..
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
demosoft()
End Sub
Private Sub demosoft()
filenumber = FreeFile() 'We assign the number which represents which file to open
If IO.File.Exists(Application.StartupPath & "\check.myext") Then 'Checking if file exists..
FileOpen(filenumber, Application.StartupPath & "\check.myext", OpenMode.Random, OpenAccess.ReadWrite) 'If exists,were opening it in readwrite mode.
FileGet(filenumber, times_used) 'Were reading from the file the value thats stored..ie the number of times he has used
MsgBox("You have executed this software " & (times_used) & " times") 'hmmm,were displaying it here..:)
FileClose(filenumber) 'Lets close the file now.
If times_used >= max_limit Then 'Were checking if the user has used the software more than the limit specified
MsgBox("Sorry,Your trial period is over!!Please purchase this software ;-) ") 'oops,if it has exceeded,then,he cant use it :p ;)
Application.Exit() 'Say Goodbye to the user..cos,he needs to purchase..We exit our app here.
End If
times_used = times_used + 1 'if he has used it once before,lets make it 2 now since this is the 2nd time
FileOpen(filenumber, Application.StartupPath & "\check.myext", OpenMode.Random, OpenAccess.ReadWrite) 'storing the value back here :)
FilePut(filenumber, times_used)
Else
'This part is if the user is using the software for the 1st time.The file has to be created
FileOpen(filenumber, Application.StartupPath & "\check.myext", OpenMode.Random, OpenAccess.ReadWrite)
FilePut(filenumber, times_used) 'ok,now he has opened and used once,so,lets write it in here.
End If
End Sub
Godwin
Help someone else with what someone helped you! 
-
Aug 24th, 2005, 10:01 AM
#13
Hyperactive Member
Re: Expiry date for demo product
hmmm, I have some little experience with this one..which most of my projects has a database included, either you can use a windows registry put some date or number of uses there, encrypt it or whatever you want...
But sometimes I made it so simple. made some variables like
Public glDemo Const = True
Public gnMaxRecord = 15
then compile it, make a package & deployment and deliver the CD to the client. Trapping it in the recordcount...
The catch is, you want your client to like you software so you gave them all functionality there but it has something like this on every transactions or record added
If glDemo Then
If rsTable.RecordCount = gnMaxRecord Then
Msgbox ("Maximum record reached for DemoVersion.Please purchase this software")
Exit Sub
End If
End If
Have a nice day.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|