.WriteVarToTerminal

Syntax

WriteVarToTerminal "Variable", MaxLength, Erase, Echo

Description

Copies the variable value to the current terminal cursor position.

Command Parameters

Variable Select a defined variable to be copied to the terminal position.
   
   
MaxLength Argument type: Integer
  The maximum number of characters to write to the terminal.
   
Erase

If you select Yes and the length of the variable contents is less than MaxLength, all other characters up to MaxLength will be erased.

   
Echo If you are modeling a block mode application, select the Don't wait for echo option. If you are modeling a character mode application, select from the following options:
  • Don't wait for echo (Default)—Select this option to transmit the string to the host and immediately move to the next action. Always use this option for block mode applications. For character mode applications, use this option only when you know that data will not be echoed back to the terminal screen. For example, many times alphanumeric keys are used to move between screens and are not echoed.

  • Wait for next tabstop—Select this option to wait for the cursor to appear at the next tabstop after transmitting data. If tabstops have been defined on the Cursor tab, then Host Integrator waits for the cursor to appear at one of the defined locations. If no tabstop definitions are applicable, then Host Integrator waits for the cursor to be anywhere on the screen that is outside the attribute or recordset field to which the data is being written.

  • Wait for next tabstop or string to echo at cursor—Select this option to wait for the exact data string to be written back to the terminal screen or to wait for it to appear at the next appropriate tabstop. This option is not recommended.

  • Wait for same number of characters to echo—Select this option to wait for the same number of characters to be sent back to the terminal screen after data has been transmitted to the host. To detect the number of echoed characters, Host Integrator transmits the data and waits for the cursor position to move the same number of columns as the length of the data transmitted. For example, if you transmit the name George as your password, a host will often echo six spaces instead of the original text. With this option selected, Host Integrator waits for the cursor to move six columns from the cursor position when the name George was transmitted to the host before moving on to the next command.

  • Wait for string to echo at cursor—Select this option to wait for the exact data string to be written back to the terminal screen after data has been sent to the host. This is the most robust option to select when working with character mode hosts. Note: With character mode applications, the cursor must be wherever characters are being written to the screen. For this reason, use this option to synchronize with the host application.

  • Wait for cursor to arrive at specific location—Select this option to wait for the cursor to arrive at a specified location.

Related Topics
Bullet Mapping an attribute to a variable
Bullet Configuring variables