cancel
Showing results for 
Search instead for 
Did you mean: 

Working with Dropdown

Contributor

Working with Dropdown

Hello team,

 

I have application and i would like to work with dropdown option for my website.

 

Specially i need to first click on dropdown and then select first item from the list.

 

Please share the steps for Keyword Test, attached is the screenshot where I need your assistance.

 

Could you please assist in the same.

9 REPLIES 9
Community Hero

Re: Working with Dropdown

What have you tried?  Have you used Object spy to figure out the object and it's methods?  You can try recording selecting the item and see what TestComplete finds.  Once you do so, you can make whatever modifications you want.


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available
Contributor

Re: Working with Dropdown

yes, i have tried working with what Testcomplete finds during recording of the dropdown

 

However, whenever i playback the recorded steps I do not get the item selected and it says unable to find keyword dropdown.

 

Best,

Prabhjot

Occasional Contributor

Re: Working with Dropdown

Try to catch the item you want to select with object spy with point and fix and choosing the specified item and press Shift+Ctrl+A in this way you can see if the class of the dropdown is recognized.

I had the same problem with selecting the dropdown items on desktop application build in Delphi, after adding the class of the dropdown Tools->Current Project Properties->Open Aplication->Text Recognition all items from the dropdown were recognized.

I had also follow the steps from the link Compiling Delphi 2007 Applications With Debug Information  and rebuilding new .exe my application is working more fast and stable, the controls are recognized.

 

 

 

Contributor

Re: Working with Dropdown

Tried , but still Testcomplete is unable to identify the dropdown element.

 

Can we schedule a call sometime and I can screen share you the issue.

 

Best,

Prabhjot

Community Hero

Re: Working with Dropdown

Your error sounds like one of timing where the drop down control is perhaps not available immediately upon selection.  Is there an activity you're doing before you attempt the drop down that may require the page to load or refresh?


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available
Contributor

Re: Working with Dropdown

Nopes, no other activity,

It is a simple dropdown click which is not being recognised by TestComplete keyword script

Community Hero

Re: Working with Dropdown

So, it cannot find the drop down?  

There's an "Additional Info" panel on the log for that error.  Can you provide that information?

Also, what was mapped for the drop down control?  Are there variable components in the properties (ID's, etc) that change from run to run?  It might have mapped fine the first time but might need to be adjusted.


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available
Highlighted
Contributor

Re: Working with Dropdown

Hello,

 

There the logs:

 

The object with the specified attributes does not exist.

Possible causes of the error



Tested object:
Aliases.browser.pageMyOptrustPensionOnlineServic.panel.panel.panel.panel.nav.link
(Sys.Browser("chrome").Page("https://penweb-uat-web.penweb.local/member/penweb/app/dashboard").Panel(0).Panel(0).Panel(0).Panel(0...))

 

Also, please note these are not variable properties, Link dropdown has the same properties everytime it loads.

 

Lets setup a call. Please assist.

 

Best,

Prabhjot

Community Manager

Re: Working with Dropdown

Hi @prabhjot88singh,

Based on the error you get, TestComplete cannot find the object. It means that mapping criteria have been changed since the time you had created the test. It's worth checking the criteria you use to make sure that they are reliable (contain IDs, names, etc.).

---------
Tanya Gorbunova
SmartBear Community Manager

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others.↓↓↓↓↓
New Here?
Join us and watch the welcome video:
API Testing Mistake #2
APITestingMistake#2
Top Kudoed Authors