<p>When DogProtect protects an application it records the date. The licensing system treats this date as a build date of the application. And you can put into a serial number the maximum build date this serial number can work with. Therefore, if you put the current date plus one year to the serial number, it will work with all versions of your programs you will be releasing in a year. A version you release one year and a day after will not work with this serial number, and a user will have a choice: use older version of your program or purchase a new key to work with the latest version of the program for one more year.</p><strong>Let's try it</strong>
<p>Put the line formatted as MaxBuildDate=YYYYMMDD into the ini-file:</p>
<preclass="code">MaxBuildDate=20000101
</pre>
<p>In the test mode, the licensing system treats today as the build date, so it is important that the date specified in this line already passed. That is, the maximum date is yesterday. Modify the code of the <strong>main()</strong> function so that it looked like this:</p>
<preclass="code">int main(int argc, char **argv)
{
char *serial = "Xserialnumber"; // we set the serial number directly in the code, for simplicity