Create HOST Modules

This chapter describes how to create HOST Modules.

For information on how to steer HOST controls, see chapter "Steer HOST Engine 3.0 controls".

Scan your HOST application

You create HOST Modules with Tosca  XScan.

To do so, right-click a Module folder and select Scan->Remote Terminal. Alternatively, click on the dynamic menu Modules and select  Scan->Remote Terminal.

You can only scan active, connected HOST emulator sessions.

The sections below describe how to create Modules with the HOST controls Label, TextBox, and Table.

Scan HOST Labels

The control Label allows you to steer messages in your HOST application.

To create this control, follow the steps below:

  1. In the HOST Scan window, select  Label.

  2. In the Content Preview area, highlight the line where your text is located. Tricentis Tosca automatically uses the following properties to define your control:

    • Height specifies the height of the label.

    • Width specifies the width of the label.

    • Column specifies the on-screen position of the starting column of the label.

    • Row specifies the on-screen position of the starting row of the label.

  3. Click  Finish Screen and then  Close.

Scan HOST TextBoxes

The control TextBox allows you to steer texts and execute keyboard commands in your HOST application.

To create this control, follow the steps below:

  1. In the HOST Scan window, select  TextBox.

  2. Click on Search TextBoxes to search for text boxes, or highlight the content in the Content Preview area. Tricentis Tosca automatically uses the following properties to define and locate your TextBox:

    • Height specifies the overall height of the control.

    • Width specifies the overall width of the control.

    • Column specifies the on-screen position of the starting column of the control.

    • Row specifies the on-screen position of the starting row of the control.

  3. Click  Finish Screen and then  Close.

Scan HOST Tables

To create a Module to steer tables, follow the steps below:

  1. In the HOST Scan window, select  Table.

Table in a HOST application

  1. By default, Tricentis Tosca counts every line as a row. If you want to choose a different height for each row of your table, use the following property:

    • RowHeight specifies the row height. The default value is 1.

  2. Select  Area and highlight the outer area of your table in the Content Preview area. Alternatively, you can define the area manually in the Properties pane.

    Tricentis Tosca uses the following properties to define and locate your table:

    • Height specifies the overall height of the table.

    • Width specifies the overall width of the table.

    • Column specifies the on-screen position of the starting column of the table.

    • Row specifies the on-screen position of the starting row of the table.

    • NoScroll specifies whether the table spans over multiple screens or not. The default value is False.

    • ScrollForwardKey specifies the key to scroll the table forward. The default value is {F8}.

    • ScrollBackwardsKey specifies the key to scroll the table backwards. The default value is {F7}.

  3. Select  Columns and define the columns of your table in the Content Preview area. Alternatively, you can define the columns manually in the Properties pane.

    Tricentis Tosca uses the following property to identify the columns of your table:

    • ColStartList is a comma-separated list for the first character of every column, relative to the control coordinates. This property always starts with 1.

  4. By default, Tricentis Tosca uses the first row as the header of a table. If you want to use a different row as header, select  Header and define it in the Content Preview area. Alternatively, you can define the header manually in the Properties pane.

    Tricentis Tosca uses the following properties to identify the header of your table:

    • HeaderRow specifies whether the table has a header or not. The default value is -1 for a table without a header. If you define a header, this value changes to 1.

    • HeaderHeight specifies the height of the header, counted from the top of the table. The default value is 0.

  5. Click  Finish Screen and then  Close.

Avoid saving HOST Module with the wrong screenshot

Tricentis Tosca saves the Modules that you create with HOST Engine 3.0 with an attached screenshot. The attached image is of the content that was visible on the preview screen when you clicked Finish Screen.

If you navigate to another screen in your HOST emulator, the image doesn't change in the HOST Scan content preview automatically. This can result in saving a Module with the wrong image.

To avoid saving Modules with the wrong screenshot attachment, follow the steps below:

  1. Before you navigate to another screen in your emulator, click Finish Screen.

  2. Navigate to the desired screen in your HOST emulator.

  3. Click Scan Screen and select controls that you want to scan on that screen. The image in the HOST Scan content preview changes to show the right emulator screen.