Forum Discussion

m1013864's avatar
m1013864
Occasional Contributor
14 years ago

EvaluateXPath not working in TC8.6 and IE8

I am having problem in using TC8.6 EvaluateXPath expression.



The problem is that the expression is unable to find any web elements for a valid xpath. the code sample is pasted here



var page=Aliases.Sys.iexplore.pageObject;   //This is the mapped page object

//btnXpath="/html/body/div/div[2]/div[2]/div/div[3]/div[3]/div/span/span/span/span/button";

var objectReturned=page.EvaluateXPath("/HTML/DIV/DIV[2][@id='dijit_form_Button_*']");



The object returned is a null object of variable type 1 in TC8.6



Could some one please let me know what could be the possible reason? I have tried various combination of xpaths directly from Mozila Firebug.



My objective is to use the expression to find elements in IE and Mozila both

1 Reply

  • irina_lukina's avatar
    irina_lukina
    Super Contributor

    Hi Pawan,


    We've just released a new version of TestComplete (ver. 8.70). So, I recommend that you update TestComplete to this version and try running your test again.


    Does the problem persist?