I use the ‘Select item’ activity to select items from a dropdown. I have used the ‘Select item’ activity for this desktop application, and it worked fine. However, for this particular dropdown, it doesn’t work as expected. The items in the dropdown of the actual application are different, and the ‘Select item’ activity contains the same value multiple times, which is not even present in the application’s dropdown. Although there are multiple items in the ‘Select item’ activity, they all have the same value. How can I fix this issue?
SyntaxEditor Code Snippet
This is the correct selector that I obtained from UI Explorer. When I analyze it, I see that ‘idx=2’ changes based on the number of tabs I have open when selecting this dropdown
so what can be done
hello @pd2897
The dropdown is a custom control, so UiPath can’t detect its items. Instead of using Select Item, click the dropdown, type the desired value, and press Enter.
If select item does not work
Then you need to use a while loop inside that use check app state to check if the element is present..
On present side use click with dynamic selector with ineertext as variable
If not present then on the other ise use mouse scroll activity
Cheers
Could you please explain this solution in detail?
- When you say “element is present,” are you referring to the dropdown itself or the items within the dropdown?
- If it is the dropdown, why do we have a loop?
- I didn’t understand the actions for when the element is present and when it is not present.
- If I understand correctly, when the element is present, we need to identify the dynamic selector. How can we obtain the dynamic selector using a UiPath activity?
- Item level not dropdown level..so create a dynamic selector with innertext as variable and pass the required item value in innertext
- when select item does not work we need to use click plus mouse scroll to go the item in the dropdown
- when present click on the item to select, when not present that means item might be at the bottom after scroll so use mouse scroll once to get the next set of items and as it is in loop it will check again and then click or scroll based on presence
- open ui explorer and indicate one single item..create a selector with innertext and add a variable in place of the value…to test pass different values and check if it is identifying the items..eg:
<webctrl tag='DIV' innertext='{{variablename}}' class='ABC' />
cheers
Thank you for the answer, but this didn’t work
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.

