Hi Community members, ![]()
Today, we are back with a new articles on Desktop Testing with Katalon!
Have you ever been frustrated when trying to capture and interact with items in a dropdown list?
As the dropdown list’s items are in a separate window, we cannot capture or interact with them directly but need to perform some extra steps like switching to a desktop and switching to a separate window containing the list of dropdown list’s items.
Let us share with you a scenario and how to work around it.
Scenario
- Try to capture items of a dropdown list in a desktop application.
- Try to click on an item in a dropdown list in a desktop application.
Issues & Solutions
1. Cannot capture items of the dropdown list
Do you use the “Windows Action Recorder“? If yes, please use the “Native Windows Recorder“ instead.
Windows Action Recorder will use all methods of Appium to capture and interact with desktop elements. There will be some limitations like capturing dropdown list items.
Aware of those limitations, Katalon developed a new function named “Native Windows Recorder“ to cover most of the cases.
See a comparison between Windows Action Recorder and Native Windows Recorder below ![]()
Windows Action Recorder
Native Windows Recorder
2. Cannot interact with items of the dropdown list when executing the test
As explained above, we need to perform extra steps to interact with items in the dropdown list since they belong to a separate window.
So, what are the extra steps?
- Switch to Desktop where we can find or interact with other available Windows applications.
- Interact with the item in the dropdown list.
Note: Since the items list is shown on a window without a title, so we need to make sure that the system can find the item correctly based on the defined locator.
For example, instead of using the xPath locator /List/Listitem[2]
we should use another locator like Name with a specific value like VNI
- Switch back to the application to continue performing actions on other objects
We would love to provide you - our community users - with the custom keyword below to save time…
@Keyword
def clickDropdownItem(WindowsTestObject windowsObject) {
Windows.switchToDesktop();
Windows.click(windowsObject);
Windows.switchToApplication();
}
Result
If you find this article helpful, then don’t forget to leave us a like
or a heart
, and share it with your colleagues, to show your support!
To read other KShare articles, simply navigate to our #product-insights category.



