Calling apm.stop.clock from javascript (646 Views)
Reply
Advisor
Tutino
Posts: 34
Registered: ‎02-21-2011
Message 1 of 4 (646 Views)
Accepted Solution

Calling apm.stop.clock from javascript

Hello everyone,

                             Does anybody knows how to call the rad application "apm.stop.clock" from javscript? I need to stop the clocks from a script.

 

Thanks in advance!

Tino

Please use plain text.
Valued Contributor
Pikutj
Posts: 78
Registered: ‎05-26-2011
Message 2 of 4 (644 Views)

Re: Calling apm.stop.clock from javascript

Hello Tino,

 

Use rtecall fucnation to caal the subroutine apm.stop.clock as follow :

system.functions.rtecall("callrad",rteReturnValue,"apm.stop.clock",rteNames,rteValues,false)

script would be like,

var rteReturnValue = new SCDatum();
var rteNames = new SCDatum();
var rteValues = new SCDatum();

//Parameter names for RAD
rteNames.push(<parameter1>);
rteNames.push(<parameter2>);
//add any number of parameter according to requirement
similarly add parameters to rtevalue

rteNames.setType(8); //type array
rteValue.setType(8); //type array


system.functions.rtecall("callrad",rteReturnValue,"apm.stop.clock",rteNames,rteValues,false)


regards,

Please use plain text.
Advisor
Tutino
Posts: 34
Registered: ‎02-21-2011
Message 3 of 4 (641 Views)

Re: Calling apm.stop.clock from javascript

Thanks a lot Pikutj!!

Please use plain text.
Valued Contributor
Pikutj
Posts: 78
Registered: ‎05-26-2011
Message 4 of 4 (639 Views)

Re: Calling apm.stop.clock from javascript

Little correction.

use inverted commas in passing values in arrays as below,

rteNames.push("name"); // clock name
rteNames.push("prompt");


Please use plain text.
The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation