P
PaleRider
Hi again,
I have code that prevents the use of a form after a certain amount of days.
What I didn't consider is someone just changing the date on the computer.
Now, I have to figure out how to handle that otherwise it's a mute point.
The code I have in place so far has flaws that can be exploited. Is there a
way to allow someone limited use of database for a certain time frame, then
disable it after that?
Here's the code I have so far which allows use for 14 days, but as mentioned
before it can be exploited by just changing the system date:
Private Sub Form_Open(Cancel As Integer)
Dim myDate As Date
myDate = #6/2/2009#
If DateDiff("d", myDate, Date) >= 14 Then
MsgBox "Your 7 day evaluation for this database has expired."
Cancel = True
End If
End Sub
-PR
I have code that prevents the use of a form after a certain amount of days.
What I didn't consider is someone just changing the date on the computer.
Now, I have to figure out how to handle that otherwise it's a mute point.
The code I have in place so far has flaws that can be exploited. Is there a
way to allow someone limited use of database for a certain time frame, then
disable it after that?
Here's the code I have so far which allows use for 14 days, but as mentioned
before it can be exploited by just changing the system date:
Private Sub Form_Open(Cancel As Integer)
Dim myDate As Date
myDate = #6/2/2009#
If DateDiff("d", myDate, Date) >= 14 Then
MsgBox "Your 7 day evaluation for this database has expired."
Cancel = True
End If
End Sub
-PR