The Get Web Dropdown block retrieves the selected option from a dropdown element on a web page. It returns the selected index, text, and value for use in downstream blocks. This block only works with browser windows that were opened using the Start Web Browser block or their “child” windows.
Fully expanded, the Get Web Dropdown block shows the following properties:
Note: The screenshot on this page uses the Elegance Design, introduced in 2025.3. If you are using an earlier version, your layout may look different.
For guided examples of how to capture and configure web elements, refer to the Learning Center tutorials.
Quick-start
Drag Get Web Dropdown onto the canvas.
Specify the basic parameters required for this block to operate: Select Dropdown element.
Run the flow when it’s ready.
Building block parameters
Parameters
Block header: The green input connector triggers the block to start executing. The green output connector triggers when the dropdown has been successfully read. You can rename the block title (“Get Web Dropdown”) by double-clicking it and typing a new title.
Select Dropdown Element: Contains the locator for the dropdown web element to read. You can capture a locator by right-clicking and selecting Capture new web element, edit it via Edit web element, and clear it via Clear web element.
Selected Index: Provides the index of the selected dropdown option as an output that can be connected to other building blocks.
Selected Text: Provides the text of the selected dropdown option as an output that can be connected to other building blocks.
Selected value: Provides the value of the selected dropdown option as an output that can be connected to other building blocks.
Not found: Triggers if the dropdown element is not found before the timeout. This is typically used to branch execution flow or to explicitly fail a case by linking it to a Fail block.
Default timeout: If the checkbox is not selected, the timeout is 10 seconds. If the checkbox is selected, the Default timeout value from the flow settings applies.
Timeout: The maximum time spent searching for the dropdown element before giving up and triggering Not found. This is separate from the case global timeout in Settings, which can cancel a run if the whole case exceeds it.
Source element: Limits the dropdown locator to only search inside a specified source element (for example, within a previously found table element).
Browser window: Makes the block use a specific browser window. Multiple browser windows are not supported by Selenium Grid or external cloud providers such as Sauce Labs and BrowserStack.
Use Occurrence: Selects which occurrence of the dropdown to use when more than one match is found. Select All to iterate through all occurrences; the block output triggers for each occurrence, and Current index and Completed are shown.
Current index: When iterating through all occurrences, contains the current occurrence index being processed.
Completed: Triggers when the iteration of all occurrences has completed.
Count: Contains the total number of found dropdown elements that match the locator.
Await DOM change: Delays the search until there have been no changes to the page’s DOM for a specified period (for example, 3 seconds). Regardless of this checkbox, the action proceeds after waiting a maximum of 30 seconds.
Await Timeout: The number of seconds the DOM must have had no changes before proceeding.
Await Requests: Delays the search until there have been no active XHR requests for a specified period (for example, 3 seconds). Regardless of this checkbox, the action proceeds after waiting a maximum of 30 seconds.
Guidelines for understanding and using the Strategy Editor in Leapwork to define, refine, and validate robust locator strategies for UI elements using DOM structure, tokens, and wildcards.