SAP commands
SAP commands are dynamic advanced commands that enable your wizard to perform tasks in SAP, like getting text and values, locating objects, and logging in and out. Use these commands to manage and automate SAP processes smoothly and effortlessly.
Before you begin:
Learn how to navigate the Nintex Wizard Editor of the Studio.
Understand how to create wizards and use advanced commands.
Understand variables.
Learn how to customize error handling within an advanced command.
Understand how to configure wizard fallbacks.
-
SAP Win GUI installed
-
SAP GUI scripting configured on the server and local machine
-
Nintex Studio access
-
A wizard created in the Wizard Catalog
-
Dynamic advanced commands installed
Before using SAP commands, make sure SAP Win GUI is installed, and enable SAP GUI scripting on both your server and client machines for robots. This allows reliable automation in the SAP Win GUI environment. Ensure this configuration on the local machine where SAP Win GUI is installed for both Studio and Robots before initiating SAP automation projects.
For detailed server and client configuration steps, refer to the SAP documentation.
Refer to the table below for a detailed overview of each command and its respective functionalities:
Command | Description |
---|---|
Click on SAP object | Click on an SAP GUI window elements, such as toolbars, menus, checkboxes, buttons, in the current user interface. |
Does SAP object exist |
Check if an SAP object exists in the current UI and store the result in a variable. This command is useful with the If Else command to conditionally perform an action based on its presence. |
Extract SAP table text | Extract text fields from an SAP table and store it in a variable. You can choose specific rows and columns for extraction. Use this command for interacting with tables (standard, grid, ALV) and trees (simple, list, column). |
Get SAP object location |
Retrieve an SAP object's location (in pixels) in the active application and store it in new or existing variables. *See Considerations. |
Get SAP object text |
Retrieve the text of an SAP object in the active application and store it in a new or existing variable. *See Considerations. |
Get SAP object value |
Retrieve the value of an SAP object in the active application and store it in a new or existing variable. This command is useful for checking the value of checkboxes, radio buttons, drop-down lists, etc. *See Considerations. |
SAP login | Log into an SAP system. |
SAP logout | Log out of an active SAP connection. |
Set SAP object value |
Insert a value into an SAP object in the active application. *See Considerations. |
-
* The commands marked with an * in the table above require a recorded step before the command, and they cannot consist only of Advanced Commands. If there is no recorded step before the SAP command, a warning may appear, stating, "The following commands are not supported at this position and will be removed."
-
The SAP interfaces consist of various controls, each with its own set of capabilities. But, some limitations may apply when using SAP DACs in wizards. The table below shows scenarios where the SAP Scripting API poses challenges for different SAP elements. Additionally, where available, we've provided practical workarounds to navigate these limitations.
SAP Element Description Limitations Workaround Line item table Displays a table of line items which contain sets of cells and provides options for selecting the items.
The SAP Scripting API has limitations when dealing with certain tables. While it enables opening the table and clicking on table items, it doesn't support capturing the bounding rectangles of these items.
Due to the Object Selector's difficulty in detecting a single cell in a table, we recommend using visual detection during the recording process as a workaround. Context menu Displays a list of options. It can have multiple child menus within a main menu.
The SAP Scripting API has limitations when dealing with context menus. Although it enables opening the context menu and clicking on menu items, capturing the bounding rectangles of each item is not supported.
Due to the Object Selector's difficulty in detecting a single element within the context menu, we recommend using visual detection during the recording process as a workaround. Menu Enables the selection of items from the SAP Menu. The SAP Menu is only available in the main SAP WinGUI window.
The SAP Scripting API has limitations when dealing with menus. Although it enables opening the menu and clicking on menu items, capturing the bounding rectangles of each item is not supported. Due to the Object Selector's difficulty in detecting a single element within the menu, we recommend using visual detection during the recording process as a workaround. ALV table A type of SAP tables represented by a standard set of controls for elements displayed in a tabular structure.
In certain cases, the ALV table may seem like two tables visually, even though it's technically one. Header information may also be part of the table structure, making it challenging to distinguish between cells. There's currently no known workaround. You can try using visual detection as an alternative. Simple tree A type of SAP tree represented by a list of elements organized in a tree structure.
The SAP Scripting API has limitations when dealing with trees. Although it allows you to select the entire tree, it does not allow you to capture specific elements within the tree.
Due to the Object Selector's difficulty in detecting a single element within the tree, we recommend using visual detection during the recording process as a workaround. List tree A type of SAP tree represented by a list of elements organized in a tree structure with lists in unorganized columns.
The SAP Scripting API has limitations when dealing with trees. Although it allows you to select the entire tree, it does not allow you to capture specific elements within the tree. Due to the Object Selector's difficulty in detecting a single element within the tree, we recommend using visual detection during the recording process as a workaround. Column tree A type of SAP tree represented by a list of elements organized in a tree structure with organized columns.
The SAP Scripting API has limitations when dealing with trees. Although it allows you to select the entire tree, it does not allow you to capture specific elements within the tree. Due to the Object Selector's difficulty in detecting a single element within the tree, we recommend using visual detection during the recording process as a workaround. Visual detectionFollow the steps below to use visual detection for the SAP elements that are not recognized with commands:
SAP Win GUI must be added to the list of allowed applications in the Nintex Admin for this to be successful.-
Log in to the Studio.
-
Create a new wizard.
-
Click GET STARTED.
-
Click RECORD in the center of the display pane. This minimizes the Wizard Editor window and displays the Nintex Recorder.
-
Click Record (F11) on the Nintex Recorder.
-
Open the SAP application to the specific area where there is a limitation.
-
Press F11on your keyboard to stop the recording.
-
Select the wizard step that shows the limitation in the Navigation pane, for example if there was difficulty identifying the menu item in SAP.
-
Click Insert from the main menu.
-
Select Window from the menu drop-down.
-
Select Visual object from the Window drop-down.
-
Click the place on the screen with the object that was not captured due to the limitations. The Window Object box shows around the object.
You can add multiple window objects by repeating this procedure. Each additional window object is a fallback in case the preceding window object is not detected. -
Select Never to disable the Bring window to front option in the Window tab of the Flow pane when dealing with menus and context menus.
-
Save the wizard by either clicking Wizard > Save or by clicking the icon on the toolbar.
-