Sendida ( idasymbolicname, session ), Sendtext ( text, session ), Object = session ( index ) – Casio Naurtech CETerm Ver.5.5 Scripting Guide User Manual
Page 28

N
AURTECH
W
EB
B
ROWSER AND
T
ERMINAL
E
MULATION FOR
W
INDOWS
CE
AND
W
INDOWS
M
OBILE
CETerm Scripting Guide
Page 28
defined script from the web browser. To execute a script contained in a string
from the CETerm engine use the JavaScript “eval()” method.
SendIDA ( IDASymbolicName, session )
SendIDA sends an IDA action command and directs it to the specified session.
Valid session values are 1 to MaxSession. The special session value of 0 will
send the command to the current session. See Appendix 1 for IDA Symbolic
Names.
The SendIDA method will attempt to complete the action before returning. We
recommend using PostIDA rather than SendIDA. There are only rare situations
when SendIDA must be used. For example, SendIDA will be needed if you
need to invoke IBM field actions, such as Field Exit, between sending text to an
IBM session with SendText.
SendText ( text, session )
SendText sends a text string to the specified terminal emulation session. Valid
session values are 1 to MaxSession. The special session value of 0 will send the
command to the current session. This command is synchronous and CETerm
will act on each character before this method returns. SendText will not send
text to a browser session. To change text into a browser page, use the
Browser.Document reference and assign the text directly to the desired page
element.
The text string may include IDA symbolic names between backslash characters
„\‟. The IDA codes will be interpolated as the text is sent. For example,
“username\\IDA_FIELD_EXIT\\secretpassword”. Note that each backslash has a
preceding backslash because it is the JavaScript
“escape” character. To put a
single literal backslash in a string you precede it with another backslash.
object = Session ( index )
Return the corresponding Session object. Valid index values are 1 to
MaxSession. The object is returned even if the session is not connected.
intervalTimerID = SetInterval ( scriptExpression, delayMillisec )
Set a recurring interval timer to execute the scriptExpression after each delay of
delayMillisec. This method returns an ID that should be saved in a global variable
for later use with ClearInterval if needed. Other scripts may run while waiting for