brijmitchell
9 years agoContributor
Why has wItemList disappeared
For some reason the wItem property has seem to have disappeared from the object we are using.
This is preventing the test from selecting the correct option from the dropdown, i dont believe anything has changed as it was working one minute and not another.
so our current function does not work, does anyone have any ideas?
function selectDropDownItem(theDropDown, theItem) { theDropDown.WaitProperty("Exists", true, MEDIUM_LENGTH_TIMEOUT); theDropDown.WaitProperty("VisibleOnScreen", true, MEDIUM_LENGTH_TIMEOUT); //theDropDown.Click(); //This was commented out as it was clicking out of place see TAP-381 //theDropDown.parent.Click(); //This was commented out as it was clicking out of place see TAP-381 var list = (theDropDown.wItemList) //LogToHTML(list); var tokens = tokenize(list, ";"); for (var i = 0; i < tokens.length; i++) { //LogToHTML(tokens[i]); if (aqString.Trim(tokens[i]) == theItem) { var index = i; break; } } LogToHTML(index); theDropDown.WaitProperty("Exists", true, MEDIUM_LENGTH_TIMEOUT); theDropDown.WaitProperty("VisibleOnScreen", true, MEDIUM_LENGTH_TIMEOUT); //theDropDown.Click();//added this to get the report items styles to work - may have broken other code elsewhere? theDropDown.ClickItem(index);
When i run the function i get the following error, The object with the specified attributes does not exist.
This is odd as this function has been working perfectly fine for ages, when i try and remap the object i am still not seeing the wItemList.