Comments on: Selenium: How to Handle Windows-Based Dialogs and Pop-Ups https://testguild.com/selenium-how-to-handle-windows-based-dialogs-and-pop-ups/ Tue, 06 Sep 2022 21:03:16 +0000 hourly 1 By: Mel https://testguild.com/selenium-how-to-handle-windows-based-dialogs-and-pop-ups/#comment-278032 Tue, 11 Apr 2017 15:00:54 +0000 https://testguild.com/?p=1969#comment-278032 Thanks for this, it was very useful. Can you provide any insight into utilizing AutoIt on a Selenium GRID set up?

]]>
By: Joe Colantonio https://testguild.com/selenium-how-to-handle-windows-based-dialogs-and-pop-ups/#comment-203805 Wed, 17 Feb 2016 13:32:00 +0000 https://testguild.com/?p=1969#comment-203805 In reply to Bharat.

You could probably use SikuliX which works on Windows, Linux and Macs

]]>
By: Bharat https://testguild.com/selenium-how-to-handle-windows-based-dialogs-and-pop-ups/#comment-202816 Thu, 11 Feb 2016 08:56:57 +0000 https://testguild.com/?p=1969#comment-202816 Any tool that can be used on OS X (Mac) ?

]]>
By: Joe Colantonio https://testguild.com/selenium-how-to-handle-windows-based-dialogs-and-pop-ups/#comment-179384 Fri, 16 Oct 2015 12:59:26 +0000 https://testguild.com/?p=1969#comment-179384 In reply to Richie.

Hmm not sure – are there multiple browser windows open for your tests? Do using driver.switchTo() help?

]]>
By: Richie https://testguild.com/selenium-how-to-handle-windows-based-dialogs-and-pop-ups/#comment-179012 Wed, 14 Oct 2015 23:50:44 +0000 https://testguild.com/?p=1969#comment-179012 After clicking “Cancel” button to close my Windows popup, i try to find an element on the browser page and get an error “Unable to find element on closed window”. Any recommendations?

Thanks a lot Joe for all of your knowledge sharing.

]]>
By: Vishwathma https://testguild.com/selenium-how-to-handle-windows-based-dialogs-and-pop-ups/#comment-174716 Wed, 23 Sep 2015 05:27:43 +0000 https://testguild.com/?p=1969#comment-174716 Hi,

Thanks for the info. I appreciate your efforts for sharing this useful info. I have implemented the code in the same fashion & I was able to interact with the dialog. But my test case also needs to interact with a .ini file. On trying to use iniWrite or iniRead to read & write into the .ini file an exception is thrown. I googled but I didn’t get any solution. Am stuck now & am unable to proceed further without getting a solution for this issue. Please help me. Your help would be highly appreciated.

AutoItX x = new AutoItX();
x.iniRead(“F:\\Simulator\\DeviceSimulatorV0.8\\DefaultSimulator.ini”, “DefaultSimulator”, “Addr”, “”);
//String fileName = “\\DefaultSimulator.ini”;
//x.iniWrite(fileName, “UDP ADDRESS”, “Addr”, “54.244.118.62”);

Trying to use iniWrite, this is the exception:
FAILED: calc
com.jacob.com.ComFailException: Can’t map name to dispid: IniWrite
at com.jacob.com.Dispatch.invokev(Native Method)
at com.jacob.com.Dispatch.invokev(Dispatch.java:625)
at com.jacob.com.Dispatch.callN(Dispatch.java:453)
at com.jacob.activeX.ActiveXComponent.invoke(ActiveXComponent.java:476)
at autoitx4java.AutoItX.iniWrite(AutoItX.java:349)
at autoIt.CalcTest.calc(CalcTest.java:53)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:85)
at org.testng.internal.Invoker.invokeMethod(Invoker.java:648)
at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:834)
at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1142)
at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:124)
at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:108)
at org.testng.TestRunner.privateRun(TestRunner.java:771)
at org.testng.TestRunner.run(TestRunner.java:621)
at org.testng.SuiteRunner.runTest(SuiteRunner.java:357)
at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:352)
at org.testng.SuiteRunner.privateRun(SuiteRunner.java:310)
at org.testng.SuiteRunner.run(SuiteRunner.java:259)
at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:52)
at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:86)
at org.testng.TestNG.runSuitesSequentially(TestNG.java:1176)
at org.testng.TestNG.runSuitesLocally(TestNG.java:1101)
at org.testng.TestNG.run(TestNG.java:1009)
at org.testng.remote.RemoteTestNG.run(RemoteTestNG.java:111)
at org.testng.remote.RemoteTestNG.initAndRun(RemoteTestNG.java:204)
at org.testng.remote.RemoteTestNG.main(RemoteTestNG.java:175)

Trying to use iniRead, this is the exception:
FAILED: calc
com.jacob.com.ComFailException: Can’t map name to dispid: IniRead
at com.jacob.com.Dispatch.invokev(Native Method)
at com.jacob.com.Dispatch.invokev(Dispatch.java:625)
at com.jacob.com.Dispatch.callN(Dispatch.java:453)
at com.jacob.activeX.ActiveXComponent.invoke(ActiveXComponent.java:476)
at autoitx4java.AutoItX.iniRead(AutoItX.java:331)
at autoIt.CalcTest.calc(CalcTest.java:49)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:85)
at org.testng.internal.Invoker.invokeMethod(Invoker.java:648)
at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:834)
at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1142)
at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:124)
at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:108)
at org.testng.TestRunner.privateRun(TestRunner.java:771)
at org.testng.TestRunner.run(TestRunner.java:621)
at org.testng.SuiteRunner.runTest(SuiteRunner.java:357)
at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:352)
at org.testng.SuiteRunner.privateRun(SuiteRunner.java:310)
at org.testng.SuiteRunner.run(SuiteRunner.java:259)
at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:52)
at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:86)
at org.testng.TestNG.runSuitesSequentially(TestNG.java:1176)
at org.testng.TestNG.runSuitesLocally(TestNG.java:1101)
at org.testng.TestNG.run(TestNG.java:1009)
at org.testng.remote.RemoteTestNG.run(RemoteTestNG.java:111)
at org.testng.remote.RemoteTestNG.initAndRun(RemoteTestNG.java:204)
at org.testng.remote.RemoteTestNG.main(RemoteTestNG.java:175)

]]>
By: Reddy https://testguild.com/selenium-how-to-handle-windows-based-dialogs-and-pop-ups/#comment-160189 Thu, 02 Jul 2015 14:56:37 +0000 https://testguild.com/?p=1969#comment-160189 Hi Joe ,,,
Nice posting on windows Pop-Ups, can we have any other methods for windows Pop-ups like you said ” AutoIt ”, we find only this method for automating window Pop-Ups , can you share any other methods for windows
Pop-Ups.( where selenium webdriver can handle )

thanks
Reddy

]]>
By: Joe Colantonio https://testguild.com/selenium-how-to-handle-windows-based-dialogs-and-pop-ups/#comment-159078 Tue, 23 Jun 2015 20:32:20 +0000 https://testguild.com/?p=1969#comment-159078 In reply to Dwarika.

Thanks!

]]>
By: Dwarika https://testguild.com/selenium-how-to-handle-windows-based-dialogs-and-pop-ups/#comment-158767 Sun, 21 Jun 2015 16:34:25 +0000 https://testguild.com/?p=1969#comment-158767 Thanks for posting this article on handling windows based dialogs and pops ..

]]>
By: Joe Colantonio https://testguild.com/selenium-how-to-handle-windows-based-dialogs-and-pop-ups/#comment-158406 Thu, 18 Jun 2015 19:24:54 +0000 https://testguild.com/?p=1969#comment-158406 In reply to srinath.

Hi – the link should now be fixed https://testguild.com/downloads/UISpy.zip let me know if you still have issues. Thanks

]]>