I need help to resolve issue of multiple similar matches found. The drug search popup box lists the drugs and does not have dropdown for selection. Also, how can I fix it to where the changing drug name will be selected correctly each time.
Hello @choppers1868 ,
Instead of using Select Item because this popup isn’t a standard dropdown try using a dynamic selector approach. Here’s how:
- Anchor to the list container of the popup.
- Use Click Text or Find Element activities.
- Inject the drug name dynamically with
CurrentRow("Drug Name").ToString.
This method ensures that your automation reliably selects the correct drug, even when the name changes, and avoids the “multiple similar matches found” issue.
Best regards,
Ghaith
Use dynamic innertext selector
- Open Select Drug Name activity.
- Indicate on screen, then edit Selector.
- Replace the static drug text with a variable: You can just select and right click on the static text, you can select required variable or create a new variable.
Eg:
<webctrl tag='TD' innertext='{{CurrentRow("Drug Name").ToString}}' />
Avoid index-based selection
Ensure exact match with .Equals() if using Find Children
Follow the below steps,
- Click on the dropdown (List of items will be shown) using click activity.
- Take one more click activity, Indicate your option that need to select.(if it changes frequently then use variable ). To indicate your option open UiExplorer there you can select proper attributes that can relate to your item name.
Happy Automation!


