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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T15:45:19+00:00 2026-05-21T15:45:19+00:00

I am trying to work with mouseover on a particular Item in my application

  • 0

I am trying to work with mouseover on a particular Item in my application by using the following command
{

ie.text_field(:xpath, “//a[contains(text(),’Deal’)]”).fire_event(‘onmouseover’)

}

On doing mouseover on a item, two subitems are displayed.

Is there any way to capture the sub items which are part of the Item by doing mouseover with which we can report that our test is pass or fail.

Please suggest.

Additional Information :

If we take example,On the StackOver flow page, If i do mouseover on my name, i get a window where i see activity, privileges, Logout and other stuff. This is really what i was looking for. Is there a way to capture the items displayed on the window on doing mouseover.

I also tried to capture the subitems with the following :
{

text=ie.text_field(:xpath, “//a[contains(text(),’Deal’)]”).fire_event(‘onmouseover’)

puts(text.inspect)

}

On doing this “text” value is displayed as ‘nil’.

  • 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-21T15:45:20+00:00Added an answer on May 21, 2026 at 3:45 pm

    My general tactic for such things is a combination of using IRB and the IE Developer tool, or Firebug.

    using IRB, type out (or cut and paste) the watir statement to fire the onmouseover command to the proper element on the page.

    Then have the developer tool rescan the DOM (there’s a little refresh icon you can click) The use the tool to point to an element to point to one of the items in the stuff exposed by the onmouseover. Using the info from that, you can then figure out how to address those elements to get the text from the proper div, etc.

    If I do that here to the info that opens up when I float the mouse over my name I can find out that it is a table of class “profile-recent-summary” Furthermore I can then look at the way the table is made up and see for example that the ‘today’ reputation value is in the second cell on that row.. The row also has the text ‘reputation’ in it.. so

    browser.table(:class, 'profile-recent-summary').row(:text, /reputation/).cell(:index, 2).flash
    

    Should flash the cell I want (index might be 1 if using firewatir or webdriver) I can then replace the .flash with something else like .text if I want to get the text from that cell (which is actually inside a link that sits in the cell)..

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

Sidebar

Related Questions

Weve recently been trying to work on an application that uses pandastream to encode
I'm trying to launch a CLI command from a PHP script: in particular I
I'm trying to get the highlight/hover/mouseover styles working for a KMZ Placemark using Google
I have a simple mouseover event that I am trying to work on elements
I'm trying to get mouseover to work polygons in google maps api v3. I've
I am trying work out with MERGE statment to Insert / Update Dimension Table
Trying to work with Eclipse for Android (ADT plugin) development at my iMac (2.4Ghz,
Trying to work with groupby so that I can group together files that were
When trying to work with Qt's signal/slot mechanisms over more than one level of
Programming Student here...trying to work on a project but I'm stuck. The project is

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.