While ACCELQ's label-based identification is the preferred strategy for SAP automation, many complex UI elements—such as specific icons, nested grids, and controls without unique text labels—require Smart Locators. This guide explains the step-by-step process for capturing SAP screens and managing these locators in the repository.
1. Capturing SAP View
Capturing an SAP view creates a visual and technical snapshot of the current screen. This snapshot allows you to interact with the underlying SAP object tree to define unique locators for elements that cannot be reached via simple text labels.
1.1 Prerequisites
- The ACCELQ RPA Server must be running and connected.
- The SAP GUI Client must be open to the target screen.
- SAP Scripting must be enabled on both server and client sides.
2. Step-by-Step View Capture
To bring an SAP screen into ACCELQ for element identification:
- Open the Action or Logic Editor where you are building your test.
- In the sidebar, click on "Views".
- In the top menu, click the "..." icon and select "New SAP Screen View".
- Ensure the target SAP window is the active window on your desktop. ACCELQ automatically detects and pulls the UI hierarchy of the active window directly into the View Canvas via the RPA bridge.
Note: Login Screen Capture
The initial SAP login screen (where credentials are entered) is not capturable via the View Capture process. Attempting to capture this screen will not yield interactable elements.
3. Saving and Configuring Smart Locators
Once the capture is complete, ACCELQ displays the screen within the View Canvas for interaction and element identification.
3.1 Interaction with the Captured View
- You can hover over elements to see how ACCELQ highlights the SAP object boundaries.
- Right-click the specific element you need (e.g., a "Search" icon next to a field or a complex data table) to initiate the save process.
3.2 Naming and Repository Storage
- After right-clicking and selecting Save Element, provide a descriptive, logical name (e.g.,
Material Lookup IconorVendor Invoice Table). - The element is now stored in the Element Repository and can be reused across different Actions within the same Context.
3.3 Automated Locator Generation
In SAP automation, ACCELQ simplifies the locator definition process:
- Unique Identification: When you save an element, the system automatically retrieves the unique locator string from the SAP GUI scripting engine.
- Reliability: This string directly identifies the object within the SAP hierarchy, ensuring that the automation targets the exact control intended without requiring manual selector engineering.
4. Working with Captured Elements in Logic
Once an element is saved to the repository, you can utilize it in the Logic Editor using "Element-based" commands. Below are examples of how these elements are utilized:
Click on a SAP UI Element.Is SAP UI Element exists.- Table commands like
Set value of a cell in SAP UI Table.
Note on SAP Login Screen
As the SAP login screen is not capturable, you must use the built-in ACCELQ login commands directly in your logic.
- Command:
Log in to SAP Session - Workflow: This command handles the connection selection and credential entry automatically at the protocol level. Do not attempt to build a manual "Enter Text" flow for the login screen using Smart Locators.
Comments
0 comments
Please sign in to leave a comment.