18 January 2026:
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
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.
[Help] Different data brought up by different browsers in same web page.
Hi seniors:
sahi v4.4
I met a problem,
"In the same web page", to through IE9 to catch(a link), was showing _link(Edit). When uses another browser(Chrome 29.xx) to catch,
it was showing _link(EDIT), what's going on that ?
are there somebody experienced that? please share
thanks in advance~
BR
Wei
sahi v4.4
I met a problem,
"In the same web page", to through IE9 to catch(a link), was showing _link(Edit). When uses another browser(Chrome 29.xx) to catch,
it was showing _link(EDIT), what's going on that ?
are there somebody experienced that? please share
BR
Wei
This discussion has been closed.
Answers
Sahi can identify elements using plently of identifiers.
Does using _link("Edit") or _link("EDIT") cause any problems while running the script?
Regards.
Have encountered this issue some time back.
Solution 1: Please make your script browser based. (eg : _isChrome(), _isIE())
Solution 2 : Check for ui elements(e.g: id, name,label) other than _link which remains constant across the browsers and use that.
Quoted:
"Does using _link("Edit") or _link("EDIT") cause any problems while running the script?"
Yes, it happened halt to go next stage while using _link("Edit") on Chrome browser(was catched _link("EDIT")).
FYI
BR
Wei
Thanks for you replied,
Quoted:
"Solution 1: Please make your script browser based. (eg : _isChrome(), _isIE())"
I don't know what that mean for,
could you show me further detial for that? (or explain me more)
BR
Wei
I agree with what Sarath Krishnan has suggested above.
I think I understand what he suggested above and will try explaining what he meant.
So, Sahi has APIs like isIE, isChrome, isFF etc what return true or false based on which browser you're running the script on.
eg. isIE will return true for IE8, IE9, IE10 etc (all IE versions) and false for firefox, chrome etc.
So as an example, to click the edit link your script should be something like this:
Please let me know if you need any further clarification in this matter.
Regards.
wow, thanks sharing such good solution,
It works very well.
sincerely appreciating.
BR
Wei
Glad to help.
I will be closing this discussion now.
Regards.