nish_b
6 years agoContributor
[TestComplete JS] ClickItem() is not working for dropdown
Hi,
I have a web application which has a multi-select dropdown with some values which looks the one in screenshot named dropdown
(Note: There are some values in dropdown but I have overwritten by the highlighter as its not necessary info for this).
My requirement is that I need to click on 1 of the items in the dropdown based on the text. For example, if I have a text named as "Apple" in the dropdown. I want to click on that. I similated the action and converted to script using Record Script. I got the below command for this:
vselect.ClickItem("Apple");
But this is not working. When I re-run this script it throws the error: "Cannot activate the 'Apple' item"
Can you please help?