TestCoeUs1337
7 months agoOccasional Contributor
Selecting n-th element using CSS selector
Hello everyone,
I'm currently working on automating a date-picker element in TestComplete, and I'm trying to achieve a functionality similar to what I've done in other frameworks using CSS selectors. In my case, I locate 30 buttons that represent days in a month.
My question is, can I store the CSS selector of these buttons in a variable and then click on a specific day, for example, the 5th, by passing the index to it and using the .Click() method?
(I've done it previously with cypress using .eq(index) to click on the given element?
Any insights or examples on how to accomplish this in TestComplete would be greatly appreciated. Thanks in advance!