cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Have a PTC product question you need answered fast? Chances are someone has asked it before. Learn about the community search. X

Can I set a period of time when I deploy a DLL?

CHASEONHO
18-Opal

Can I set a period of time when I deploy a DLL?

Can I set a specific lifetime when deploying a DLL?

 

Or can I set up additional licenses for C language programs?

 

If possible, please explain what you need to do.

 

Thanks a good weekend

ACCEPTED SOLUTION

Accepted Solutions

Expected this question as well. 

 

Implemented a scenario with below details:

 

  • During deployment , create a file and it should be in encrypted format.
  • If file is not found, you should deny to start toolkit code.
  • During each toolkit code run, set variable in encrypted file with current date and time. (You should fix this date time format irrespective of system date time format)
  • Before each new run, check and validate that current date and time should not be previous date and time saved into encrypted file.

 

-HIH

Ketan

 

View solution in original post

4 REPLIES 4

It's possible. We have achieved the same.

 

Below should be done in user_initialize() :

  • Get current date from system using c++ functions. Compare the same with your designated valid date and compare both the dates.
  • If current date is not falling within your case, do return message to user about expiry date and return -1 for user_initialize().

HIH

Ketan

 

It is a very good offer!
But the system time can be changeable

The above conditions are not particularly attractive if you change the system time.

Is there any other way?
For example, can I see that the system time has changed?

Expected this question as well. 

 

Implemented a scenario with below details:

 

  • During deployment , create a file and it should be in encrypted format.
  • If file is not found, you should deny to start toolkit code.
  • During each toolkit code run, set variable in encrypted file with current date and time. (You should fix this date time format irrespective of system date time format)
  • Before each new run, check and validate that current date and time should not be previous date and time saved into encrypted file.

 

-HIH

Ketan

 

It's fun!
I saved the time when the toolkit was run as a binary file to a * .dat file.
Then compare the time stored in the file with the current time.
If the current time is after the saved time, the toolkit exits.
Thank you.

Announcements


Top Tags