Forum Discussion
rraghvani
2 years agoChampion Level 3
Here's an example of using the FindAll method on a list box, to print out each of the item names from the UI Control
function testit()
{
// Use with https://demos.devexpress.com/Bootstrap/Editors/ListBox.aspx
var page = NameMapping.Sys.browser.Page("https://demos.devexpress.com/Bootstrap/Editors/ListBox.aspx");
var listbox = page.Form("form1").Panel(2).Section("content").Panel(0).Panel("Content_ListBoxDefault");
var items = listbox.FindAll("ObjectType", "Link", 1);
// List item names
for (var i = 0; i < items.length; i++) {
Log.Message(items[i].contentText);
}
}
You can adapt this method, to pass in a parameter, to select the appropriate item from your dynamic dropdown list.
Related Content
- 7 months agopaarmann-ara
- 9 years agoteak