[wtr-general] Re: Can I get the abscissa and longitudinal coordinates of a link/button/textfield on the page?

2009-09-03 Thread Dylan
, as well as the ability to left or right click at certain coordinates, which I assume you'll need if you don't directly get the element you're trying to click. -Dylan On Sep 3, 3:44 am, Wesley Chen cjq@gmail.com wrote: Hi, Guys, Now, there is a link on the page, can I get the abscissa

[wtr-general] Re: Code to select values in combo box

2009-09-02 Thread Dylan
http://pettichord.com/watirtutorial/docs/watir_cheat_sheet/WTR/Cheat%20Sheet.html -DYLAN On Sep 2, 9:27 am, naveen kumar naveeenku...@gmail.com wrote: Hi Friends, I am new to ruby watir can any one send the code for selecting values is combo box please send me different WAYS OF SELECTING

[wtr-general] Re: Check value of anonymous text field

2009-09-02 Thread Dylan
You can look through \ruby\lib\ruby\gems\1.8\gems\watir-1.6.2\lib\watir \collections.rb for the types of collections that watir recognizes, as well as a good idea on how to add your own. -Dylan On Sep 2, 7:18 am, manar alalfi alalfi.ma...@gmail.com wrote: Thanks a lot for you all. The solution

[wtr-general] Re: Does Watir support PHP based technology

2009-09-02 Thread Dylan
recommend upgrading to the latest version of watir. -Dylan P.S. As far as I know there is no selection_box element type. http://pettichord.com/watirtutorial/docs/watir_cheat_sheet/WTR/Cheat%20Sheet.html On Sep 2, 10:37 am, rrash586 rrash...@gmail.com wrote: Thanks for ur reply

[wtr-general] Re: Check value of anonymous text field

2009-09-02 Thread Dylan
? ie.text_fields.each{|tf| tf.set(watir) if(tf.value != and tf.name !=) } Of course, thats going to go through and change any text field to watir whenever it has a name value and there's already text in it, and I have no idea why you would want to do that. :) -Dylan Thanks, thats works fine. However

[wtr-general] Re: customize xml generated by ci_reports

2009-09-01 Thread Dylan
in the File.open call. It should look something like this: http://pastie.org/601390 -Dylan On Aug 31, 9:47 pm, Marlon marlonmoja...@gmail.com wrote: Hi, how can I rename the filename of the xml created by ci_reporter? I need a repository and store the test results generated. ex. TEST- Class NameDate

[wtr-general] Re: Reading special characters

2009-09-01 Thread Dylan
Also, you can get around the special character (so you dont have to look each one up) by using a regex and the regular text: browser.text.include?(/Previous/) browser.span(:text,/Previous/).click On Sep 1, 6:52 am, GJHmf graham.harb...@webroster.net wrote: How annoying; I thought I had tried

[wtr-general] Re: after massive watir crawl..

2009-08-29 Thread Dylan
Well, if you're crawling tens of thousands of pages you might have picked up a nasty bug somewhere along the way. I would run some virus scans. Also run some network diagnostics (try pinging some sites, etc...) -Dylan On Aug 29, 8:04 am, curious csamigr...@gmail.com wrote: I have massive WATIR

[wtr-general] Re: Not able to enter login credentials in Sign In section

2009-08-26 Thread Dylan
the text_field elements might be in there. You could try: $ie.frame(:index,1).text_field(:name,Email).set(a) frames hide their html from the parent frame/window, so if the login fields are in a frame, looking for the fields in the main window wont work. -Dylan On Aug 26, 4:55 am, Maumita

[wtr-general] Re: Watir fire_event that opens a modal dialog no wait needed

2009-08-25 Thread Dylan
More details are probably required. What action is performed instead, for instance? On Aug 25, 12:51 am, Adrian Ghidu agh...@gmail.com wrote: Sorry for the late reply, but the fire_event_no_wait method is not working: the expected action is not performed. Thanks On Thu, Jul 30, 2009 at 5:26

[wtr-general] Re: onMouseover

2009-08-25 Thread Dylan
? -Dylan On Aug 25, 2:05 pm, sd qajan2...@gmail.com wrote: Hi, I have an item. Once I mouseover that item, I get an image which I need to click on.  I used fire_event(onMouseover) which shows me the button which is an image, but I need to click on that image. Using .click on that image

[wtr-general] Re: customize xml generated by ci_reports

2009-08-24 Thread Dylan
://pastie.org/593268 It probably wont work for you because I've made some changes to how the reporter outputs the xml file, but it should give you the basic idea. -Dylan On Aug 23, 11:52 pm, Test Test checktestingthi...@gmail.com wrote: Tony, I have added Class.Attr contents and now its working

[wtr-general] Re: How do I get a URL parameter value

2009-08-18 Thread Dylan
Can you do $ie.frame(:index, 1).src ? -Dylan On Aug 17, 11:09 pm, Marlon marlonmoja...@gmail.com wrote: Im getting an error retrieving src value which is https://url.com/ text.asp?p=xyzq=abc using attribute_value() code: $ie.frame(:index, 1).attribute_value(src) Error: NoMethodError

[wtr-general] Re: How do I get a URL parameter value

2009-08-18 Thread Dylan
I was just offering another way he might do it. I'm not at my machine w/ ruby/watir so I cant test it right now. =Dylan On Aug 18, 12:28 am, Raveendran P jazzezr...@gmail.com wrote: Hi Dylan, *Way 1:* Please provide the code/site URL I will try and let u know *Way 2:* puts $ie.frame

[wtr-general] Re: how to click link with CTRL key pressed in watir?

2009-08-17 Thread Dylan
http://wtr.rubyforge.org/rdoc/classes/Watir/IE.html#M000256 -Dylan On Aug 16, 11:32 pm, Bhavesh bhavesh1_sha...@yahoo.com wrote: Actually  currently i press CTRL key manually and then the link, it gets opened. But while automating how can i do this? Plz dont suggest to remove pop-blocker

[wtr-general] Re: Is there anyway to wait until all images of a page is not loaded properly.

2009-08-17 Thread Dylan
Try something like: Water::Waiter.new(10).wait_until{$ie.image(:id,imgid).exist?} using one of the images. -Dylan On Aug 17, 7:18 am, Maumita maumita.majum...@gmail.com wrote: Hi, I have written a script to capture the page download time. The page has different shopping item images along

[wtr-general] Re: How can i click CTRL key + Link in Watir

2009-08-17 Thread Dylan
See my reply to your other message, and please only create one discussion per topic at a time, thanks. :) -Dylan On Aug 17, 12:05 am, Bhavesh bhavesh1_sha...@yahoo.com wrote: Hi , I have to click CTRL key + link using watir. Is anybody know how to do it? Actually i can tmodify any

[wtr-general] Re: IE.attach doesn't work properly in the script

2009-08-16 Thread Dylan
This might not be your issue, but have you tried adding a require watir/ie line? If that doesn't help, please provide information on what versions of watir and ruby you're using. -Dylan On Aug 16, 10:17 pm, balbao ramkrishn...@gmail.com wrote: Folks, Have any of you faced similar kind

[wtr-general] Re: Is there any way to run a watir script automatically in every hour.

2009-08-12 Thread Dylan
each image and wait till it exists. If an image doesn't get loaded in 20 seconds it will throw a Timeout Exception. I've had a lot of problems with the way Watir waits for things and haven't really found a good solution overall. -Dylan On Aug 12, 1:52 am, Tony ynot...@gmail.com wrote: Hi

[wtr-general] Re: Right Click

2009-08-12 Thread Dylan
as variables passed to right_click (with defaults of 0) so I can move the mouse into the element more with a call like ie.element(:id,//).right_click(30,10) Thank you so much for your help, I can't believe I missed that. :) -Dylan On Aug 12, 3:16 pm, tcfodor tcfo...@comcast.net wrote: Hi Dylan

[wtr-general] Re: How to fill the info in the TEXTAREA?

2009-08-12 Thread Dylan
The text_field element should also work for text areas. -Dylan On Aug 12, 9:18 pm, yuping zhong littlezhong...@gmail.com wrote: Dear All, I am a new user of Watir. It is known to all that fills the info in the text_field is easy. But how to fill the info in the TEXTAREA? I give more info

[wtr-general] Re: How to run 2 different scripts at the same time?

2009-08-11 Thread Dylan
{test_google2} threads[0].join threads[1].join -Dylan On Aug 10, 10:30 pm, Marlon marlonmoja...@gmail.com wrote: for example: require 'thread' require 'watir' class search   def test_google     ie = Watir::IE.start('http://www.google.com')     ie.text_field(:name, q).set(pickaxe

[wtr-general] Re: How can I add a new method to Watir::Radio?

2009-08-11 Thread Dylan
Try looking at where the radio methods are defined in watir, that should give you a clue. In input_elements.rb, the declaration of Radio functions look like this: Module Watir class Radio RadioCheckCommon def myMethod puts this is my method end end end -Dylan

[wtr-general] Re: How can I add a new method to Watir::Radio?

2009-08-11 Thread Dylan
Try adding require 'watir/ie' after your require 'watir' line -Dylan On Aug 11, 2:03 am, John Kolokotronis johnj...@gmail.com wrote: Thanks - I noticed the Radio class is in input_elements.rb and tried the structure you suggested before my original post: module Watir    class Radio

[wtr-general] Re: please let me know how to identify whether the chechk box present in the page is checked or unchecked

2009-08-10 Thread Dylan
class: def checked? return true if(self.html =~ /CHECKED/) return false end then you can used the checked? method. Hope this helps! -Dylan On Aug 10, 2:56 am, ravilla lavanya.ravi...@gmail.com wrote:  I got one problem while running the automation script: I am having 20 checkboxes

[wtr-general] Re: How to run 2 different scripts at the same time?

2009-08-10 Thread Dylan
You can do this in ruby with threads (http://ruby-doc.org/core/classes/ Thread.html) although you need to be very careful that the two threads don't interfere. -Dylan On Aug 10, 7:44 pm, Marlon marlonmoja...@gmail.com wrote: Hi, anyone here knows how to run multiple scripts at the same time? I

[wtr-general] Re: Issue with a PopUP and Click_No_Wait

2009-08-09 Thread Dylan
which version of 1.86? :) I know its confusing, but 1.86 - 27 does not work with click_no_wait, while 1.86 - 26 does. You can download it here: http://rubyforge.org/frs/download.php/29263/ruby186-26.exe -Dylan On Aug 9, 10:20 am, Pallavi Sharma write2pall...@gmail.com wrote: I am using ruby

[wtr-general] Re: Verify does not work while checking the links.

2009-08-05 Thread Dylan
Well, I'm not sure if this is your problem but that isn't a global variable, its an instance variable. Global variables start with $ -Dylan On Aug 5, 2:51 am, Yuvraj yuvrajjagad...@gmail.com wrote: Hi, I have installed the ruby 1.8.6 and WATIR 1.6.2. I am checking whether a link is active

[wtr-general] Re: graph/charts

2009-08-04 Thread Dylan
I would ask generic ruby questions here: http://groups.google.com/group/comp.lang.ruby/topics -Dylan On Aug 4, 12:38 pm, anna barbara ostrowska ab.ostrow...@gmail.com wrote: Hi there, Can you recommend me any tool/ruby library that allows me convert data (metrics) to graph/charts ect

[wtr-general] Re: Problem setting select_list using an array index

2009-08-03 Thread Dylan
Your welcome! A good thing to do when you're using variables that aren't being accepted like you think they should be is to output them to the screen right before you use them (print org[0]), that way you know exactly what value is getting used. -Dylan On Aug 3, 6:21 am, infoDrone xrandywe

[wtr-general] Re: Error while retrieving an integer from spreadsheet

2009-08-03 Thread Dylan
Add .to_i in the middle there, because like you said you aren't getting an integer back, so you have to make it one. So you end up with: $regno = oo.cell(row,6).to_i.to_s -Dylan On Aug 3, 8:52 am, balbao ramkrishn...@gmail.com wrote: HI, Am a novice in Watir and have a problem in retrieving

[wtr-general] Re: Watir Install/Basic Error, It doesn't launch browser

2009-08-03 Thread Dylan
I would try uninstall/reinstalling and running gem update --system beforehand so you have the latest version of rubygems before you try installing watir. I promise nothing, though! :) -Dylan On Aug 2, 8:12 pm, DF df.tra...@gmail.com wrote: I am totally new and just trying to learn and do basic

[wtr-general] Re: Getting an error saying undefined method `length' when trying to use date in a text field.

2009-08-03 Thread Dylan
Date.today() returns a Date object, while .set requires a string. Somewhere in the set function it is trying to get the length of the string it was passed, which is why you're getting that error. You might try something like: ie.text_field(:name,q).set #{today} -Dylan On Aug 3, 10:18 am

[wtr-general] Re: Problem setting select_list using an array index

2009-07-31 Thread Dylan
=File.open(orgs.txt,r) f.each{|line| org.push line.gsub(\n,)} f.close return org end org=get_orgs(org) ie.select_list(:id,'id').select(org[0]) -Dylan On Jul 31, 2:58 pm, infoDrone xrandywe...@yahoo.com wrote: I have a select_list with values of Coke, Pepsi, and Sprite. I need

[wtr-general] Re: Getting text between two br / tags

2009-07-29 Thread Dylan
, but it would get the job done. -Dylan On Jul 29, 12:47 pm, Aaron MacDonald aa...@genieknows.com wrote: There is a line of text that I want to extract.  It is found in some HTML that follows this pattern: a href=...img src=...//abr/ !-- An image link -- Some text br/ a href=...Another link (variable

[wtr-general] Re: can Watir run in remote webserver with linux OS??

2009-07-28 Thread Dylan
Don't see why not. Might be dangerous, depending on what sites you end up crawling, but a recursive loop should do the trick. You'll have to use something like FireWatir, unless you have IE on your linux web server :) -Dylan On Jul 27, 8:32 pm, Joeyjoey dorik...@gmail.com wrote: hi there, i

[wtr-general] Re: Open source tool for window apps

2009-07-28 Thread Dylan
http://www.autoitscript.com/autoit3/ -Dylan On Jul 28, 11:34 am, venky venkatesh...@gmail.com wrote: Hi, Is there any open source tool to automate window based application? Thanks, Venkathttp://prog2impress.com/ --~--~-~--~~~---~--~~ You received

[wtr-general] Re: How to access input boxes defined in an iframe

2009-07-23 Thread Dylan
I would try browser.frame(:src,xyz).div(:id,/.*/).text_field (:id,abc123) -Dylan On Jul 22, 11:14 pm, basu bas.go...@gmail.com wrote: Hi , HTML structure is like this, html     body        div           iframe src=xyz             html               body                  div

[wtr-general] Re: customize xml generated by ci_reports

2009-07-23 Thread Dylan
xml file for each suite -Dylan On Jul 23, 2:48 am, pallavi shashidhar pals.sha...@gmail.com wrote: Hi there, Am using Ci_reporter (not the one you have mentioned. The original one.) I have an ERP suite which has watir scripts of various projects under it: This is the structure: ERP

[wtr-general] Re: customize xml generated by ci_reports

2009-07-22 Thread Dylan
I just removed the require 'ClassAttr.rb' line and copy-pasted the ClassAttr code into the top of Tony's modified reporter file. -Dylan On Jul 22, 8:11 pm, Marlon Mojares marlonmoja...@gmail.com wrote: Hi, I'm still encountering no such file to load -- ClassAttr (LoadError) where should I put

[wtr-general] Re: customize xml generated by ci_reports

2009-07-21 Thread Dylan
Thanks! I have it all up and running and its perfect! I had to rework my xml stylesheet but it was totally worth it. :) -Dylan On Jul 20, 11:12 pm, Tony ynot...@gmail.com wrote: Hi Dylan, Ooops sorry missed that... Basically this class just gives some short cut methods to access the class

[wtr-general] Re: customize xml generated by ci_reports

2009-07-21 Thread Dylan
I edited it a little to fit my needs, thought I'd post it: http://pastie.org/554062 I added a passed value to the tests tag so I can easily check if the entire suite passed/failed, along with a time value so I know when the test was run. Thanks again, Tony! -Dylan On Jul 21, 11:35 am, Dylan

[wtr-general] Re: customize xml generated by ci_reports

2009-07-20 Thread Dylan
Thanks Tony! I have tried using your file and I'm receiving this error: custom_require.rb:31:in 'gem_original_require': no such file to load -- ClassAttr (LoadError) The error occurs on the line with require 'ClassAttr'. Am I missing some file? Thanks again, I appreciate the help! -Dylan

[wtr-general] Re: customize xml generated by ci_reports

2009-07-16 Thread Dylan
set to 1, even if the suite fails. Also, I still get multiple xml files created. Could you give me an example of how you call it that only results in one file? Thanks! -Dylan On Jul 15, 11:50 pm, Tony ynot...@gmail.com wrote: Hi Marlon, Have modified the ci_reporter to include passed/failed

[wtr-general] Re: Java Script pop-ups handling in WATIR

2009-07-16 Thread Dylan
in jsClicker() and just call it with a wait time of a few seconds after your click_no_wait call. Hope this helps! -Dylan On Jul 16, 8:19 am, Smruti Ranjan Kar smrutiranjan@gmail.com wrote: Hi Charley, I'm using ruby186-27_rc2 C:\Documents and Settings\userruby -v ruby 1.8.6 (2008-08-11

[wtr-general] Re: How do I stop getting emails from Watir General?

2009-07-16 Thread Dylan
Edit my membership on the right hand side, I believe. -Dylan On Jul 16, 9:42 am, Geniene Martorell martore...@hotmail.com wrote: I used to want the emails, now I don't.  I set my subscription to No Email but I am still getting emails.  I don't want to unsubscribe to stop the emails - any

[wtr-general] Re: Watir + Cruise Control

2009-07-13 Thread Dylan
Thanks everybody! I think I have a handle on how I'm going to set this up now. I really appreciate the help! -Dylan On Jul 12, 10:22 pm, pallavi shashidhar pals.sha...@gmail.com wrote: Hi there, We have used cruise control to run our test suites. We have structured our test scripts

[wtr-general] Re: How to check the load time of an page?

2009-07-13 Thread Dylan
If I'm understanding you right, you want your test to never take more than 20 seconds, and if the page isn't loaded by then put that in the log? If so, you would need something like click_no_wait for goto (or you can justwrite a tiny html file that just has a link to the page and call

[wtr-general] Re: Watir + Cruise Control

2009-07-10 Thread Dylan
Thank you for the response. Unfortunately, we are already pretty well entrenched with Cruise Control here and aren't really looking to change to a new system. -Dylan On Jul 9, 5:03 pm, marekj marekj@gmail.com wrote: I use Hudson. has a ruby and rake plugin. I use custom workspace for all

[wtr-general] Watir + Cruise Control

2009-07-09 Thread Dylan
! -Dylan --~--~-~--~~~---~--~~ 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

[wtr-general] Re: Dealing with font, table and triggering Javascript

2009-07-08 Thread Dylan
out there, hope that helps. -Dylan On Jul 8, 1:14 am, Željko Filipin zeljko.fili...@wa-research.ch wrote: On Tue, Jul 7, 2009 at 7:52 PM, Dylan mej...@gmail.com wrote: I've even copied the exact html and ruby code given in the What to do for elements not having class in Watir? section, and I

[wtr-general] Re: Dealing with font, table and triggering Javascript

2009-07-07 Thread Dylan
Well, I finally figured out how to add font to Watir, as you suggested, and that seems to work great. Thank you so much! -Dylan On Jul 3, 12:42 am, Željko Filipin zeljko.fili...@wa-research.ch wrote: On Fri, Jul 3, 2009 at 12:54 AM, Dylan mej...@gmail.com wrote: font class=link title=Click

[wtr-general] Dealing with font, table and triggering Javascript

2009-07-02 Thread Dylan
Hey there! I have a problem I've been banging my head against my desk on for a while now, so here's hoping someone can help. I'm trying to click on an element and I can't figure out how. I can use frame and div to get down to the place on the page where I want to click and end up like this:

[wtr-general] Dealing with font, table and triggering Javascript

2009-07-02 Thread Dylan
Hey there! I have a problem I've been banging my head against my desk on for a while now, so here's hoping someone can help. I'm trying to click on an element and I can't figure out how. I can use frame and div to get down to the place on the page where I want to click and end up like this: