If in case you are clicking on some link/image which in turn opens a new browser window then u ll need to get the handle of that new window first. Then u can execute browser.close on it. U ll need to attach the new window to a new watir browser instance. eg -> ie2 = watir::IE.new ie2.attach(:url, <url of new browser window>) ie2.close
On Wed, Dec 30, 2009 at 2:43 PM, Tester <joeni...@gmail.com> wrote: > i am running a watir script on a url. The script opens pdf documents > in new windows. There are more that 100 pdf files on opening each in > new window the window hangs and I am not able to run the entire > script. Can some one help me out in this. > Is there a method such as ie.close to close the new browser window > getting opened from the main window in watir? > > -- > You received this message because you are subscribed to the Google Groups > "Watir General" group. > To post to this group, send email to watir-general@googlegroups.com > Before posting, please read the following guidelines: > http://wiki.openqa.org/display/WTR/Support > To unsubscribe from this group, send email to > watir-general-unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/watir-general -- You received this message because you are subscribed to the Google Groups "Watir General" group. To post to this group, send email to watir-general@googlegroups.com Before posting, please read the following guidelines: http://wiki.openqa.org/display/WTR/Support To unsubscribe from this group, send email to watir-general-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/watir-general