nata wrote:
> Hi gurus,
>
> Anybody knows how to put a license in a IDL project ? I want to write
> a license for my project (only available for X days). Is it possible?
>
> Thanks
You could create a license file with a large amount of random numbers
and a few numbers at known position that hold the starting date of the
license. Then, have your main program read this file, extract the date,
and compare with today's date. The good point is that you could
automate the creation of this file in any language, including PHP, so no
need to modify your code each time you want to give your program to
someone!
example:
license = fix(randomu(100,10000)*10) ;0 to 9
license[51] = 2
license[489] = 3 ;day = 23
license[9851] = 0
license[3246] = 4 ;month = 04
license[921] = 2
license[8001] = 0
license[5675] = 0
license[4854] = 8 ;year = 2008
Now in your program, read only the specified indexes and voila! ... make
sure that no ones finds the indexes you use!!!
Jean


|