18 January 2026:


This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.



Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.

If statements don't seem to work properly

philliplphillipl Members
edited November -1 in Sahi - Open Source
I'm not sure if I'm doing anything incorrect here:

if(_condition(_containsText(_cell(_table("ctl00_c_lstCompanies_grid_ctl00"), 1, 3), "000000")))
{...DoThis...}
else
{...DoThat...}

Testing the "containsText" portion of that code shows that it's working fine and returns a true or false. When I run this, even though it tests the if statement, whether it is true or false it completely skips the "DoThis" section.

What could be wrong?

Comments

  • narayannarayan Administrators
    Could you post a sample html and the script for us to see why this may be failing?
Sign In or Register to comment.