I am unable to click the element while doing automation Same operation I am able to do it via manually I have identified the element and i am able to locate it also but the problem here is when I run the script its failing Script :
`var objNext = mainPage.WaitElement("//li//div[contains(text(), 'Next')]", 10000);
objNext.Click()`
All elements are proper and Name mapping is also in proper way
I need solution for the issue where i can perform the automation
This is just a hint that may help solve the issue: Some times, the element trigging the action in the app is not the same containing the 'label' for the action. May be the element you need to click is a sibling or a parent of the one you identify by contained text.
I suggest to open the site on your browser directly, start dev tools and look at the elements around the one you identify. Is there one of them of type button or containing a 'suggesting' tag like 'mat-button' in it's class attribute? Granted: This is a tricky task.
I hope, this helps.