Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7682347
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T18:32:51+00:00 2026-05-31T18:32:51+00:00

I have been tasked with testing the contents of several pop-ups throughout our application.

  • 0

I have been tasked with testing the contents of several pop-ups throughout our application. All the pop-ups are called using something similar to:

var win = new Window({ className: "spread", title: "Discussion", 
left: 1, width: 410, height: 300, url: "Discussion.aspx?ID=" + id, 
showEffectOptions: { duration: 0}})

Since I have been unable to access the pages through the pop-ups, I have started to directly navigate to the pages. The problem is that the pages are designed to close after processing within the page is completed. (window.close();)

When testing the pages, since I am directly accessing the page, I get the The webpage you are viewing is trying to close the window. Do you want to close this window? message.

Is there a way using Watir (not Watir-webdriven) to access the message and click Yes or No?

PS – (Using IE8 if that matters. I have attempted to find ways to disable the message, but to no avail)

UPDATE
Using IE Developer Tools, the generalized html structure with a popup looks like:

<html><body>
  <iframe><form>... (Main page here)
  <div class="dialog">
    <div class="spread_close" onclick="Window.close()"/> 
    <table><tr><td><iframe>  (table is not part of the "spread_close" div)
      <html><body><form><div><table><tr><td>
        <textarea name="txtDiscussion" id = "txtDiscussion" >

using browser.div(:class => "spread_close").exists? returns true.

using browser.text_field(:name => "txtDiscussion").exists? returns false. I assume this is because of the dual <html>.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T18:32:52+00:00Added an answer on May 31, 2026 at 6:32 pm

    You’ve got frames. That’s likely what is blocking access, odds are these are not actually a popup but a ‘lightbox’ div that uses styles and such to look a lot lie a popup or modal dialog.

    Look up the stuff on how to deal with frames on the watir wiki and you should be on your way.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm part of a testing team and have been tasked with behaving badly using
I have been tasked with writing an ADP application using Access. The back-end data
I have been tasked to develop an interactive website using java & mysql: using
I have been tasked to create a form designer application in Windows Forms. The
I have been tasked with securing the connection string in an classic ASP application
I have been tasked with automating our build process with msbuild. We have about
I have been tasked with taking an Access 97 application and moving the back-end
I have been tasked with creating a Software Installation Approval section for our Intranet.
I have been tasked with looking for a performance testing solution for one of
I have been tasked with improving the current mess that is our JavaScript strategy;

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.