Miya,
Assuming the DIV value is not completely arbitrary, but is instead incrementing as you move down the page, here is how I have done it.
Set Up
- In your Object Definition, set your Path as a Parameter, not a Wildcard or Explicit value
- In the Object itself, set a local text variable, tmp_Path ( or tmp_DataElement_path, if there are multiple values being read).
- Using your example, I would set the default value to '/HTML[1]/BODY[1]/DIV[X]/DIV[1]/UL[1]/LI[1]' ('X' replacing '33')
- Set an input number variable, Line_nbr.
Action
- My Process then passes the 'intuitive' line number that I want read from the page.
- The Object takes that value and does a light calculation. Usually it is something like 'Line_nbr * 2' or '(Line_nbr * 2) + 1'
- The Object then replaces the 'X' in tmp_Path with the calculated Line_nbr
- The Object the passes the updated tmp_Path as a Parameter to the Wait and Read stages
- Lastly, of course, the Object passes the value that was read back to the Process.
There is almost certainly an argument for housing 2 and 3, above, in the Process. That would be up to you.
I hope that helps,
Red
------------------------------
Robert Stephens
Content Manager, Supply Chain
Sutter Health
America/Los_Angeles
------------------------------
Robert "Red" Stephens
Application Developer, RPA
Sutter Health
Sacramento, CA