Are you using Google in English or another language?

Adding this to your code might fix it

$KCODE = "u"
WIN32OLE.codepage = WIN32OLE::CP_UTF8

(or CP1252)

FK

2009/6/5 Miguel Argollo <miguel.argo...@gmail.com>

> HI,
>
> I´m just trying to start using xpath, so I decided to change the Google
> example in order to have some working code; I changed the
>
> ie.button(:name, "btnG").click # "btnG" is the name of the Search button
>
> line by
>
> ie.button(:xpath,"//inp...@name='btnG']/").click
>
> but I got this error msg:
>
>  Step 3: click the 'Google Search' button.
> c:/ruby/lib/ruby/1.8/rexml/parsers/treeparser.rb:90:in `parse':
> #<REXML::ParseEx
> ception: Missing end tag for 'label' (got "span") (REXML::ParseException)
> Line:
> Position:
> Last 80 unconsumed characters:
> </font></td></tr></tbody></table><table  class="gac_m" style="LEFT: 202px;
> VISIB
> I>
> c:/ruby/lib/ruby/1.8/rexml/parsers/baseparser.rb:320:in `pull'
> c:/ruby/lib/ruby/1.8/rexml/parsers/treeparser.rb:21:in `parse'
> c:/ruby/lib/ruby/1.8/rexml/document.rb:204:in `build'
> c:/ruby/lib/ruby/1.8/rexml/document.rb:42:in `initialize'
> c:/ruby/lib/ruby/gems/1.8/gems/watir-1.6.2/lib/watir/ie-class.rb:713:in
> `new'
>
> I´m using rexml 3.1.7.1, watir 1.6.2 and ruby 1.8.6
>
> Hinds will be appreciated. Thanks in advance.
>
> Miguel Argollo
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
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/display/WTR/Support
To unsubscribe from this group, send email to 
watir-general-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/watir-general
-~----------~----~----~----~------~----~------~--~---

Reply via email to