I am scripting for a Siebel application. A particular Primary Post has this section:<font color="blue">
,BODY "SWEUserName="+userName+ &
My problem is the SWETS (Timestamp) value. Now, I know the timestamp is the number of milliseconds since midnight January 1st, 1970. What I am looking for here is how I should go about the generation of this value to replace the hard-coded value in the script.
Read about the LOAD command. It can load system date and time since midnight into integer values. The system date is not, to my knowledge, based at Jan 1, 1970, but that should not stop you from using it.
The SWETS param in Siebel apps probably has to do something with timeout settings for the application (the dev team couldn't confirm this [img]/images/graemlins/mad.gif[/img]). This is being generated on the client side and so doesn't need to be correlated.
Nevertheless I implemented your suggestion for the same and replaced those hard-coded timestamps with proper variables loaded with values coming from the LOAD statement:
LOAD TIME into <integer_variable>
CONVERT <integer_variable> to <char_variable>
Now this gives me the time since midnight for the current system date. A problem here: the timer shall get reset to 0 on the next date. This might cause problem if the script execution rolls over to the next day and our virtual users might start throwing errors. A possible solution would be to include some check mechanism of comparing current date with the script start date just before loading the LOAD TIME value into our variable. If the script execution has rolled onto the next day the timer value shall be added with <u>number of 10ms ticks</u> since the start of the script execution.
Thanks Bernie for the suggestion. Hope this is of help to all others. I can help with further elaboration if somebody needs.