findelement by Xpath is way too slower than findElementByName
HI, I am trying to find and attach to a window from desktop session. When i use findElementByName the window is found within 1 second. desktopSession.findElementByName("InfoSphere DataStage Designer - DELVM07S08\dstage1 - [Parallel - dummy1]"); 2019-03-27 12:38:29.801 2019-03-27 12:38:30.110
However while using xPath it takes approx 19 seconds. (After updating to v1.1.1 it takes approx 14-15 seconds. desktopSession.findElementByXPath("//Window[contains(@Name, 'InfoSphere DataStage Designer')]"); 2019-03-27 12:54:28.829 2019-03-27 12:54:41.642
Reason for using xPath is that name is not constant and hence using contains() of xpath. NOTE: using exact name in xpath is also slow and takes approximately same time as contains().
Yes, I have same issue. As in my testing application, there is not unique attribute to identify the element, so I have to use xpath. However it takes about 10+ seconds to find the element.
Using absolute xpath generated by UIRecorder should be much faster.
Using absolute xpath generated by UIRecorder should be much faster.
Thanks. Comparing with ID, using absolute xpath is still slow, but it is much faster than relative xpath.
is there any update on this issue ? coz the problem still exists i.e findelementByXpath works very slow comparing others