V
Vani
Hello every one,
I am facing problem in Xpath query i have written to access a button
tag
in watir.
Following is the code i have written.
-------------------------------------------------------------------------
require 'watir'
include Watir
ie = IE.new
ie.goto("http://www.travelocity.com/")
ie.maximize()
ie.linktext,"Flights").click
ie.radiovalue, "oneway").set
ie.text_fieldname, "leavingFrom").set("Pune")
ie.text_fieldname, "goingTo").set("Mumbai")
ie.text_fieldname, "leavingDate").set('10/27/2005')
ie.buttonname,"submit").click
ie.linktext, "additional fees").click
sleep 5
iePopup = IE.attachtitle, /Explanation of Taxes/)
iePopup.close()
# I am facing problem on the below line of code
ie.buttonxpath,"//*[@id='tfGrid']/tr[4]/td[6]/div[1]/button").click
Can anyone tell me where I am going wrong?
I am facing problem in Xpath query i have written to access a button
tag
in watir.
Following is the code i have written.
-------------------------------------------------------------------------
require 'watir'
include Watir
ie = IE.new
ie.goto("http://www.travelocity.com/")
ie.maximize()
ie.linktext,"Flights").click
ie.radiovalue, "oneway").set
ie.text_fieldname, "leavingFrom").set("Pune")
ie.text_fieldname, "goingTo").set("Mumbai")
ie.text_fieldname, "leavingDate").set('10/27/2005')
ie.buttonname,"submit").click
ie.linktext, "additional fees").click
sleep 5
iePopup = IE.attachtitle, /Explanation of Taxes/)
iePopup.close()
# I am facing problem on the below line of code
ie.buttonxpath,"//*[@id='tfGrid']/tr[4]/td[6]/div[1]/button").click
Can anyone tell me where I am going wrong?