General information
Title:
Code to keep my code safe?
I had a friend who gave me a piece of code to protect my code thru a .dbf file he has since moved back to Germany (parts unknown). I understand most of the code but do not understand where the actual date issue is reached. I included this code into a main.prg of a new app I am about to start selling and if the file id.dbf exists I get the appropriate error. Does anyone know what to change or where to change so I can use this code in the future it must have somethiong to do with fdate but I do not see where.
Any help is greatly appreciated. Code follows:
if file("id.dbf")
* *** file exist
sele 0
use id
if allt(custid) = "5346912579" .and. allt(salesmanid) = "6245F17493" .and. allt(acctid) = "Ü924672364"
* *** entries are correct
do case
case fdate("id.dbf") < date()-6
* *** over time limit
=messagebox("You have not paid your bill in full!" +chr(13)+ "This program will not function untill you pay!", 16, "System Error")
ReturnIt = .t.
case fdate("id.dbf") >= date()-6
* *** within time limit
ReturnIt = .f.
endcase
else
* *** messed up table
ReturnIt = .t.
endif
use
else
* *** paid in full
ReturnIt = .f.
endif
return(ReturnIt)
Thanks in advance
F.
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only