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 9175475
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T16:55:10+00:00 2026-06-17T16:55:10+00:00

I am trying to retrieve, modify, and reinsert some text in a pop up

  • 0

I am trying to retrieve, modify, and reinsert some text in a pop up dialog using watir web-driver. All was going swimmingly until I tried to find a way to click the “Save Book Info” button pictured here: https://i.stack.imgur.com/pGdln.png

However I am unable to find the button. To access the pop up box I gather all the links with the correct name into an array:

    @browser.imgs.each do |img| #The links are imgs
        if img.title.include?('Edit/Delete Book')
            @books << img
        end
    end

From there I can access the links with @books[index].click. I am able to access and edit the text_fields with:

url = @browser.text_field(:name=>'url').value
... do stuff with url ..
@browser.text_field(:name=>'url').set url

But when I try and find the “Close” button I only get the buttons that are on the main page. After many headaches I managed to find the title of the window I want to work with using @browser.div(:class=>'dijitDialogTitleBar').title, which returns "Edit Book". Success! No. I still can’t figure out how to access the buttons on that popup!

If anyone could help me with this I would be most grateful. This is my first time using Watir so it’s probably a simple answer…

If more information is needed I’d be happy to supply it. Thanks in advance.

EDIT
Here is the html for the button:

<span id="dijit_form_Button_2_label" 
class="dijitReset dijitInline dijitButtonText" 
dojoattachpoint="containerNode">Save Book Info</span>
  • 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-06-17T16:55:11+00:00Added an answer on June 17, 2026 at 4:55 pm

    It looks like you have a span tag that is styled to be looked like a button. You need to access it is a span instead of a button.

    Try:

    @browser.span(:text => 'Save Book Info').click
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to retrieve product information from magento by calling its web service using
I'm trying to retrieve this page using Apache HttpClient: http://quick-dish.tablespoon.com/ Unfortunately, when I try
I am trying to retrieve RSS feed using php. The xml has many different
I'm having a strange problem while using NSDictionnary ... I'm trying to retrieve an
So I am trying to retrieve all private methods in my class that have
I'm trying to use a web service to store/retrieve info from a remote SQL
Trying to retrieve data using linq from a database. I would like to use
trying to retrieve some data from the database and put in into my form.
I´m trying to retrieve information about recurring events from sharepoint 2010 using client object
I'm trying to modify some library and I need to store a float value

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.