Select Items from dropdown list in different ways
I've to select values from a dropdown( one value at a time), but when I use the object mapping, it takes too long to locate the object. I see that the object has an Id. Is there a way I can access this object directly using it's Id and then select item from the drop-down? Can I use document.getElementById() ?
any help would be appreciated!
Solved! Go to Solution.
> Can I use document.getElementById() ?
Yes, you can but this is not recommended because of performance and convenience reasons.
.FindXXX() methods as mentioned by @YuriPeshekhonov are recommended and more preferable approach in TestComplete.
/Alex [Community Hero]
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
Thank you for suggesting Page.NativeWebObject.Find method, Yuri! I didn't know about this approach. This is really helpful.