Hi Paul,
You can use xpath to address the elements having custom attributes.
For example, to access the following input tag
input type=text name=aa mytag=paul
using xpath the code would look like this:
inText = ie.text_field(:xpath , //[EMAIL PROTECTED]'paul']/)
puts inText
Regards,
Prema
Hello people,
I do not know what command to use to make Watir output the current system date
and to convert it into the desired format, dd-mon- (22-Jan-2007). I want
the current system date inorder to check whether a particular field present in
the application has the currrent date or
Hello people,
I do not know what command to use to make Watir output the current system date
and to convert it into the desired format, dd-mon- (22-Jan-2007). I want
the current system date inorder to check whether a particular field present in
the application has the currrent date or
Hi all
I am automating test cases for a web application . Can someone please tell me
how to click on a button which has its value as a image .The code in Html says
img src=images/af/Login_button.jpg
looking for an early response..
Hi Vijay
This is a Ruby method, not specific to Watir:
Time.now.strftime(%d-%b-%Y)
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of vijay
Sent: 29 January 2007 01:51 PM
To: wtr-general@rubyforge.org
Subject: [Wtr-general] how to make Watir output the
Hi,
Please find the attached patch fixing the xpath issue.
Regards,
Prema
On 1/25/07, Bret Pettichord [EMAIL PROTECTED] wrote:
On 1/25/07, Prema Arya [EMAIL PROTECTED] wrote:
This change should be checked-in in the main branch also, Bret can you
give me access right to check-in? or
You can refer this for more date-time formats:
http://www.rubycentral.com/book/ref_c_time.html#Time.strftime
Prema
On 1/29/07, Walter Kruse [EMAIL PROTECTED] wrote:
Hi Vijay
This is a Ruby method, not specific to Watir:
Time.now.strftime(%d-%b-%Y)
-Original Message-
From: [EMAIL
On 1/29/07, vijay [EMAIL PROTECTED] wrote:
I do not know what command to use to make Watir output the current system
date and to convert it into the desired format, dd-mon- (22-Jan-2007).
Watir can not do it, but Ruby can.
Time.now.strftime(%d-%b-%Y)
= 29-Jan-2007
For more information,
Hi,
This code will click the image with name like Login_button.jpg
ie.image(:src, /Login_button.jpg/).click
Prema
On 1/29/07, ankur [EMAIL PROTECTED] wrote:
Hi all
I am automating test cases for a web application . Can someone please tell
me how to click on a button which has its value
Thank you both for your replies, but no I am not using the -b option to make IE
run hidden. This occurs sometimes with both IE6 and IE7. It seems to be
unclear what causes this mysterious behavior. For example I set up a windows
scheduled task to run a batch file that runs one of my watir
On 1/29/07, Prema Arya [EMAIL PROTECTED] wrote:
ie.text_field(:xpath , //[EMAIL PROTECTED]'paul']/)
This is so cool.
--
Zeljko Filipin
zeljkofilipin.com
___
Wtr-general mailing list
Wtr-general@rubyforge.org
I really only p[osted this for information to others who want to search the
archives. If its something that occurs a lot, it may be possible to add it to
watir directly, but Ive never seen these things used.
And does firefox support them? Allow you to access them?
Paul
On 1/29/07, Prema Arya
If your button is actually an image, for example lt;img src=...rt;, then
you should click on it using @ie.image(:src, ...).click.
-
Posted via Jive Forums
http://forums.openqa.org/thread.jspa?threadID=6309messageID=17763#17763
You need to make the scheduled job 'interactive'. It allows the job to interact
with the desktop of the user who is logged on at the time the job runs. I
typically schedule jobs through command prompt using at /interactive I
guess there is an equivalent in Scheduler as well
-Ravi
This is a Ruby Date object and its functions:
require 'Date'
myDate = Date.today().strftime(%d/%m/%y)
-
Posted via Jive Forums
http://forums.openqa.org/thread.jspa?threadID=6308messageID=17766#17766
Thanks ravishan, I am not using AT to create scheduled tasks, rather SCHTASKS
(only available in Windows XP) to create my scheduled task on the fly (when I
need it) from the command line, and there is not an option /INTERACTIVE for
SCHTASKS.
Any other suggestions?
Nathan
Thank you very much for your help! :)
Nathan
-
Posted via Jive Forums
http://forums.openqa.org/thread.jspa?threadID=6315messageID=17773#17773
___
Wtr-general mailing list
I just resolved my issue with this - you're right, it's not Watir at all,
rather it had to do with the scheduled task. In the cases where I did not see
the browser window, this was because I was logged in as a different user than
the run user that the scheduled task contained. So I changed my
Yes. I did what you wrote below and it did not work
-Suman
_
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Paul Rogers
Sent: Sunday, January 28, 2007 3:56 PM
To: wtr-general@rubyforge.org
Subject: Re: [Wtr-general] how to populate hidden text area?
presumably
can you elaborate on that?
- Original Message -
From: Suman Goel
To: wtr-general@rubyforge.org
Sent: Monday, January 29, 2007 5:08 PM
Subject: Re: [Wtr-general] how to populate hidden text area?
Yes. I did what you wrote below and it did not work
-Suman
It seems to work fine for me:
irb(main):017:0 puts ie.text_field(:id , /h/).value
abc
= nil
irb(main):018:0 ie.text_field(:id , /h/).set('gg')
WIN32OLERuntimeError: focus
OLE error code:800A083E in htmlfile
Can't move focus to the control because it is invisible, not enabled, or
of a
Since my text area is a required field and .value sets the value in the
background, when submitting the form, I get a message to fill in the details
for the required field.
I need to fill in the value on UI only. .value sets it in the background. I
need a method like .set which sets the value
can you post the html of the text area and of the button - there may be some
javascript going on.
I also dont understand that if its a required field that its also hidden?
Paul
- Original Message -
From: Suman Goel
To: wtr-general@rubyforge.org
Sent: Monday, January 29, 2007
Hi Paul,
There is definitely some java script going on because I don't see anything
in the html. Please have a look at the html.
Suman
HTML for BUTTON (Next Step)
td class=input
table width=100% cellspacing=0 cellpadding=0
border=0
tr
Hi all,
Till now I am using ie.link(:url,http//www.xyz/abc.html) for a link in
watir.Now I have a problem for the ajax link. i.e., the url obtained in the
html source is
a href=# onclick=new
Ajax.Request('/data_entry/ajax_add_term/131?contract_id=227',
{asynchronous:true,
irb(main):012:0 ie.showAllObjects
---Objects in page -
text name=aa id= value=
alt=
textarea name=hidden id=hvalue=
= nil
irb(main):013:0 ie.text_fields.show
index id
Yes we can do it in FireWatir also, there are two ways you can do:
require 'firewatir'
include FireWatir
ff = Firefox.new(5)
ff.goto(file:///F:/extras/firewatir/custom.html)
puts ff.text_field(:custom, custom).value
puts ff.text_field(:id, id).attribute_value(custom)
ff.close
html code
I forgot to mention in my previous email that on irb, this solution is
working as displayed below. But in IE, it does not since the text field is a
required field and expecting a value at the time of clicking the submit
button. I need some way to overlook that required flag of the field.
The best way to do this is to completely seperate your markup (html)
from your behaviour (js). Your link should actually point to a real URL
that works in case someone has JS turned off. This way you can select
the link with ie.link(:url, 'linkurl').
If you give the url a unique id or even a
29 matches
Mail list logo