GetKeyByIndex
Last updated
Last updated
This is pre-built Action comes for Captured Dropdown from SAP Application Element. This Action instructs the client to fetch the Key value of an item present on the dropdown list within the SAP application based on its index number and store it in an output variable.
Input: <Index>
Output: <Dynamic Variable>;<Dynamic Variable>(Optional)
The user is working on "Sales Order Creation" module in the SAP GUI application. In the "Sales Organization" field, there is a dropdown list where users can select a sales organization. Each sales organization has a unique key value associated with it (e.g., "1000" for North Region, "2000" for South Region). The test case will use the "GetKeyByIndex" Action to retrieve the key value of an item from the dropdown list based on its index number.
The dropdown list in the "Sales Organization" field contains the following items:
Index 0: "1000" - North Region
Index 1: "2000" - South Region
Index 2: "3000" - East Region
Index 3: "4000" - West Region
A user wants to fetch the key value of the sales organization at index 2 from the dropdown list, which corresponds to the "East Region." The Avo Assure will use the "GetKeyByIndex" Action to retrive the correct key value ("2000") for the given index.
2
The GetKeyByIndex Action needs to retrieve the Key according to the Input Value and save it in the Output Value.
The GetKeyByIndex Action retrieves the item according to the index which is given in the Input Value and save it in the {result} output variable as 2000, which can be utilized for display or other purposes.