This shows you the differences between two versions of the page.
5250_as400_adaptor [2021/12/29 14:05] montse [Macro generation] |
5250_as400_adaptor [2024/12/10 13:11] (current) montse [Functions] |
||
---|---|---|---|
Line 9: | Line 9: | ||
This executor must be downloaded: | This executor must be downloaded: | ||
- | {{:en:java.png?100|}} | + | {{ :en:java.png?100 |}} |
- | ===== Initialization Parameters ===== | + | ===== Initialization parameters ===== |
5250 - We are going to fill in the necessary parameters of the adapter.\\ \\ **Adapter** = 5250\\ **Session Name ** = Name that we want to give.\\ \\ **Host:**\\ - VPS = PUB400.COM\\ - TAST1 = descfvkr.de.scf.corp\\ \\ **Port:**\\ - VPS = 23\\ - TAST1 = 23\\ \\ **Proxy Port**\\ - 1080 for the 2 environments.\\ \\ **tnEnhanced**\\ - Marked for the 2 environments.\\ \\ **Screen Size**\\ - 24 * 80 for the 2 environments.\\ \\ **SSL**\\ - NONE For the 2 environments.\\ \\ ** Codepage**\\ - INTERNAL - Built-in EBCDIC conversion (CP037).\\ For the 2 environments. | 5250 - We are going to fill in the necessary parameters of the adapter.\\ \\ **Adapter** = 5250\\ **Session Name ** = Name that we want to give.\\ \\ **Host:**\\ - VPS = PUB400.COM\\ - TAST1 = descfvkr.de.scf.corp\\ \\ **Port:**\\ - VPS = 23\\ - TAST1 = 23\\ \\ **Proxy Port**\\ - 1080 for the 2 environments.\\ \\ **tnEnhanced**\\ - Marked for the 2 environments.\\ \\ **Screen Size**\\ - 24 * 80 for the 2 environments.\\ \\ **SSL**\\ - NONE For the 2 environments.\\ \\ ** Codepage**\\ - INTERNAL - Built-in EBCDIC conversion (CP037).\\ For the 2 environments. | ||
- | ===== Functions ===== | + | ===== Functions ===== |
- | * **containsText(Text):** This function evaluates whether within the host screen, there is a specific text that we define in said function.\\ 1.- In the message mapping, the text that we want to find is added in the **Value** field. | + | * **clearAndWriteField**: cleans and writes a text in the indicated field. Parameters: |
+ | * Parameter Field: field number starting with 1 | ||
+ | * Parameter Offset: offset in the field starting at 1 | ||
+ | * Parameter Value: text | ||
- | * **nextScreen:** This function directly advances to the next navigation screen previously you will have had to go through it to find it).\\ It does not require parameters in the encoding. (Function not activate at the moment). | + | * **clearField**: clears the field with field number entered in the parameter. |
- | * **previusScreen:** This function directly advances to the previus navigation screen.\\ It does not require parameters in the encoding. (Function not activate at the moment). | + | * **containsText(Text):** this function evaluates if within a host screen, there is a specific text that we define in this function.\\ 1.- In the message mapping, the text we want to find is added in the **Value** field. |
- | * **readField(Field,Offset,Length):** This function reads a field that we define in its parameters:\\ | + | * **getLenghField**: gets the length of the field with field number entered in the parameter. |
- | *Parameter = Field-> Position (numeric) in which the field is located. it is counted visually on the screen, as it is not indicated anywhere.\\ | + | |
- | *Parameter = Offset-> Position 0.\\ | + | |
- | *Parameter = Length-> Length of the field that we are going to read.\\ | + | |
- | * **readRow(Row):** This function reads a certain line from the screen. The whole line.\\ | + | * **nextScreen:** this function directly advances to the next navigation screen (you will have previously had to go through it for it to find it).\\ It does not require parameters in its coding. (Not activated this function at the moment). |
- | *Parameter = Row> Position (numeric) where the line is located.\\ \\ This data can be seen at the bottom right of the screen:\\ \\ {{:imagen1en.png?400|}}\\ | + | |
- | * **readScreen:** This function reads the screen you are positioned on.\\ Function without parameters.\\ | + | * **previusScreen:** this function directly advances to the previous navigation screen.\\ It does not require parameters in the encoding. (Function not activated at the moment). |
- | * **rowContaintsText(Text,Row):** This function checks if there is a certain text in a screen free.\\ | + | * **readField(Field,Offset,Length):** this function reads a field that we define in the function parameters:\\ |
- | *Parameter = Text -> We introduce the text to search.\\ | + | *Parameter Field: position (numeric) where the field is located, it is visually counted on the screen, since it is not indicated anywhere.\\ |
- | *Parameter = Row-> Position (numeric) of the line.\\ \\ This data can be seen at the bottom right of the screen.\\ \\ {{:imagen2en.png?400|}}\\ | + | *Parameter Offset: by default the value is always 0, which indicates the first position of the field.\\ |
+ | *Parameter Length: length of the field we are going to read.\\ | ||
- | * **waitForCursor:** This function waits for the cursor to appear on the screen that we want to see next.\\ | + | * **readRow(Row):** this function reads a particular line on the screen. The whole line.\\ |
- | *Parameter = timeinSeconds -> Value: Time in seconds.\\ | + | *Parameter Row: position (numeric) where the line is located.\\ \\ This data can be seen at the bottom right of the screen:\\ |
+ | {{ :as400sipsa.png?&400 |}}\\ | ||
- | * **writeAftherLabel (Label, Text):** This function writes any text to the screen, **after** the label that we have defined in the Label parameter has been shown (on the screen).\\ | + | * **readScreen:** this function reads the screen on which you are positioned.\\ Function without parameters.\\ |
- | *Parameter-> Label = Value-> Text to appear.\\ | + | |
- | *Parameter-> Text = Text that we are going to write.\\ | + | |
- | * **writeBeforeLabel (Label, Text):** This function writes any text to the screen **before** the label that we have defined in the Label parameter has been shown (on the screen).\\ | + | * **rowContaintsText(Text,Row):** this function checks if a certain text exists on a screen line.\\ |
- | *Parameter-> Label = Value-> Text to appear.\\ | + | *Parameter Text: enter the text to search for.\\ |
- | *Parameter-> Text = Text that we are going to write.\\ | + | *Parameter Row: position (numeric) of the line.\\ \\ This data can be seen at the bottom right of the screen.\\ |
+ | {{ :as400sipsa.png?&400 |}}\\ | ||
- | * **writeField (Text, Field, Offset):** This function writes in a certain field the value that we define in the Text parameter.\\ | + | * **waitFor**: wait for the time in seconds received in the parameter to elapse. |
- | *Parameter-> Text = Value-> Text that should appear.\\ | + | |
- | *Parameter-> Field = Field that we are going to write.\\ | + | |
- | *Parameter-> Offset = Field position (Position 0). | + | |
- | + | ||
- | * **writeKey (Key):** This function executes a predefined key on the screen.\\ (ENTER, PF8, PF4… ..etc).\\ | + | |
- | *Parameter-> Key = Value-> Function key.\\ | + | |
- | * **writeText (Text, Row, Column):** This function writes a text in a defined position.\\ (line and column).\\ | + | * **waitForCursor:** this function waits for the cursor to appear on the screen we want to see next.\\ |
- | *Parameter-> Text = Value-> Text to write.\\ | + | *Parameter timeinSeconds: value -> time to wait until the cursor appears.\\ |
- | *Parameter-> Row = Value-> Line Number.\\ | + | |
- | *Parameter-> Column = Value-> Column number.\\ \\ This data can be seen at the bottom right of the screen.\\ \\ {{:imagen3en.png?400|}}\\ | + | |
- | + | ||
- | + | ||
- | =====Macro generation===== | + | |
- | As already mentioned in the Introduction, with this adapter you can generate macros that allow you to automate tests in "transformed to HTML" systems. We are going to explain how to record a series of keyboard actions and then execute them.\\ | + | |
- | We connect to the emulator: | + | * **writeAftherLabel (Label, Text):** this function writes to the screen any text, **after** the label that we have defined in the Label parameter has been displayed (on the screen).\\ |
+ | *Parameter Label: value -> Text to be displayed.\\ | ||
+ | *Parameter Text: text that we are going to write.\\ | ||
- | {{ :es:emulador52501.png?&450 |}}\\ | + | * **writeBeforeLabel (Label, Text):** this function writes to the screen any text, **before** the label we have defined in the Label parameter has been displayed (on the screen).\\ |
+ | *Parameter Label: value-> Text to be displayed.\\ | ||
+ | *Parameter Text: text that we are going to write.\\ | ||
+ | * **writeField (Text, Field, Offset):** this function writes to a given field the value that we define in the Text parameter.\\ | ||
+ | *Parameter Text: value-> Text to appear.\\ | ||
+ | *Parameter Field: field that we are going to write.\\ | ||
+ | *Parameter Offset: position on the field (Position 0). | ||
+ | |||
+ | * **writeKey (Key):** this function executes a predefined key on the screen (ENTER, PF8, PF4, etc...).\\ | ||
+ | *Parameter Key: value-> Function key.\\ | ||
+ | * **writeText (Text, Row, Column):** this function writes a text at a defined position (line and column).\\ | ||
+ | *Parameter Text: value-> Text to write.\\ | ||
+ | *Parameter Row: value-> Row number.\\ | ||
+ | *Parameter Column: value-> Column number.\\ \\ This data is obtained from the screen, bottom right.\\ \\ {{ :as400sipsa.png?&400 |}}\\ | ||
- | Right-click to access the Recording Macro and the Record tab. | ||
- | {{ :es:emulador52502.png?&450 |}}\\ | + | |
+ | |||
+ | =====Macro generation===== | ||
+ | As already mentioned in the Introduction, with this adapter you can generate macros that allow you to automate tests in "transformed to HTML" systems. We are going to explain how to record a series of keyboard actions and then execute them.\\ | ||
+ | |||
+ | We connect to the emulator:\\ | ||
+ | {{ :as4001.png?&400 |}}\\ | ||
- | We name the file to be recorded and accept. The recording will start. | + | Right-click to access the Recording Macro and the Record tab.\\ |
+ | {{ :as4002.png?&400 |}}\\ | ||
- | {{ :es:emulador52503.png?&450 |}}\\ | + | We name the file to be recorded and accept. The recording will start.\\ |
+ | {{ :as4003.png?&400 |}}\\ | ||
- | When we finish and end the recording, we will access again with the right button to the Recording Macro and the Stop tab. | + | When we finish and end the recording, we will access again with the right button to the Recording Macro and to the Finish Recording tab.\\ |
- | {{ :es:emulador52504.png?&450 |}}\\ | + | {{ :as4004.png?&400 |}}\\ |