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.

<browser>

alamoonalamoon Members
edited November -1 in Sahi - Open Source
hi,
i want to use the <browser> two times in my code:
<browser>
...
</browser>
..
code
..
<browser>
...
</browser>

the problem ist that the program executes both browser tag simultanately than executes the remaining ode

Comments

  • narayannarayan Administrators
    Create only functions inside <browser> tags. Invoke them using _call

    Eg.

    <browser>
    function myAlert(s){
    _alert(s);
    }
    </browser>

    $x = "hi";
    _call(myAlert($x));
  • i can't do it because some functions like:
    _writeCSVFile($links_format, "U:\sahi_doc\\param.csv");
    are not accepted within the <browser> tag
  • in my programm i have to fetch links on a google search page, compare the links with links stored in archive, if there new links than the system have to navigate them and download them.
    this ist why i need to open <browser> two times
Sign In or Register to comment.