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.

Unable to get popup window Id and also a link is not working on click

vinayvinay Members
edited November -1 in Sahi - Open Source
Hi Narayan,

I am facing two new issues as of now while trying automation with Sahi:

1.) A report window is opened on click of a link. I am not able to get the corresponding window Id (new window opened).
Please suggest me how to get the Id, so that I can proceed further with the Maximize, Close, etc of it.

2.)There is a link on the web site, which am trying to automate. It's not working (on record and play) with Sahi. But it's working when a normal click is done on the application(manual).

Regards,
Vinay

Comments

  • sanjeevkumar7sanjeevkumar7 Members
    edited September 2010
    Vinay

    1) Did you try using

    _popup("popupname | information")._click(_link("Link1"));
    _popup("popupname | information").._closeWindow();

    I found most of the information in the documentation section. You can find more info in the browser API section.

    above script works for me. I'm using IE 7

    2) I had some issues with learning how things work. But it's past now.

    Hint :
    a) Use sahi controller to find the accessor/ select alternatives.
    b) press "click" when you are on the same page you are trying to record.
    c) if that works copy the expression to your script text file.
    d) If the click doesn't work try alternatives and set any value if necessary.

    Let me know how it goes.

    Best Regards,
    Sanjeeev
  • Sanjeev,

    I have tried the following for getting the window opened on click of the link, but not able to get the opened window Id:

    _popup("popupname | information")._click(_link("Link1"));
    _popup("popupname | information").._closeWindow();

    Also for the 2nd issue, am not able to get solution, as it's working on manual click of the link button, but not through the recorded script with Sahi.

    Awaiting a better suggestion from Narayan.

    Regards,
    Vinay
Sign In or Register to comment.