XPaths and Excel

Technology specific object identification, supported applications, web technologies, and 3rd party controls.
seurrep
Posts: 21
Joined: Tue Aug 07, 2018 10:19 am

XPaths and Excel

Post by seurrep » Thu Dec 06, 2018 4:32 pm

I'm trying to open, examine, modify and close excel spreadsheets generated by a call to an API end point. The creation, opening and closing is all happening without issue. What I have a problem with is that the spreadsheet has been changed so that the first sheet has a unique name in each file to match the filename. Recording actions in studio appears to create a recording that can add the figures I want to certain cells but this was when the sheet name remained unchanged from one file to the next.

The XPath to the cells in question appears to include the sheet name. Is there any way of having an XPath that uses the sheet index instead? That way the name would be irrelevent.

seurrep
Posts: 21
Joined: Tue Aug 07, 2018 10:19 am

Re: XPaths and Excel

Post by seurrep » Thu Dec 06, 2018 4:47 pm

Forget it. I just found the way of doing it via editing the path in Spy.