I can open the dropdown list using this code fine:
foreach (Control control in _form.Controls)
Element objDropDown = control.Element.FindChild(role, name, className, location);
if (objDropDown != null)
// click the dropdown list
rc = 0;
After the list is open, I don't know how to select an item. I don't know how to use the spy to get the info on the dropdown items since the dropdown list closes as soon as I activate the spy.
Class library usage, coding and language questions.
2 posts • Page 1 of 1
If you enable the HotTracker, you can also check menus and popup menus with the Spy.I don't know how to use the spy to get the info on the dropdown items since the dropdown list closes as soon as I activate the spy.
You can use the function PopupMenuSelectItem() or ContextMenu.SelectItemText() for selecting a menu item in a popup menu.
Ranorex Support Team