cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
foruiamwaiting
Level 2

Please Help me... I have reached the Corner...Please Help

I need very urgent help. Please help me. My requirement is:

1. Change the System date into LONG format (Jullian Date)
2. Have to add 30 days with the system date
3. Store it in the Registry for the expiry date.

For the above requirement i just have written the following JScript:


Generally that should return the ExpDate value.
Now my problem is
1)how can i use this JS in the CA?
2)How i can store the return value in the property table?

The JScript is giving me an error :1720 always when i was trying to run the exe file.

Please help me.......PLEASE
Labels (1)
0 Kudos
(2) Replies
RobertDickau
Flexera Alumni

For a JScript custom action, perhaps remove the XML/HTML wrapper; and you can use Session.Property("YOURPROPNAME") to set a property value for use in the registry and so on.

For example, this mess seems to work (I'm not that familiar with JScript, as you can see), setting a custom property called EXPDATE to a date 30 days in the future:
var ExpDate = new Date(new Date( ).getTime( ) + (30*24*60*60*1000));

Session.Property("EXPDATE") = ExpDate.toString( );
You can then use [EXPDATE] in the registry view to expand the property value.
0 Kudos
foruiamwaiting
Level 2

Thanks .. i will check it out and get back to you
0 Kudos