I am trying to get the xpath of particular date from from calendar. When I click the date & inspect the calendar disappears and the element also disappears from DOM. Tried with freezing the screen as well.
When I open calendar & press f8 to freeze screen the calendar disappears & screen doesn’t freeze.
I am beginner in selenium. Any help is much appreciated.
Thanks.
3
As LMC suggested, try the following…
- Use Chrome DevTools to open the page’s rendered HTML (open page in Chrome > right click on page > Inspect > select the Elements tab)
- Copy the full rendered HTML (right click the tag > Copy > Copy element) and paste it into a text editor
- Construct the XPath based on the element location (this might be helpful: https://devhints.io/xpath)