# Need assistance in error

**URL:** <https://rubytalk.org/t/need-assistance-in-error/61458>\
**Category:** ruby-talk\
**Created:** [14 January 2011 12:53 UTC](https://rubytalk.org/t/need-assistance-in-error/61458 "2011-01-14T12:53:37Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Balabaskaran\_Raghu](https://avatars.discourse-cdn.com/v4/letter/b/5fc32e/32.png) [@Balabaskaran\_Raghu](https://rubytalk.org/u/Balabaskaran_Raghu)\
**Post date:** [14 January 2011 12:53 UTC](https://rubytalk.org/t/need-assistance-in-error/61458/1 "2011-01-14T12:53:37Z")

</div>

Hi,

First and foremost I must admint that, I am completely new to watir and  
to ruby. I am trying to take my first steps in attempting to automate  
one our our testing application. And i am stuck with the error as I  
execute the script. can some one help...

I am using follow  
D:\\>ruby -v  
ruby 1.8.6 (2007-03-13 patchlevel 0) [i386-mswin32]  
D:\\>gem -v  
0.9.2  
when executing  
require 'rubygems'  
require 'watir'  
puts Watir::IE::VERSION

> ruby watir\_version.rb

1.4.1

> Exit code: 0

require 'rubygems' # the watir controller  
require 'watir' # the watir controller  
require 'win32ole' # the watir controller

# set a variable  
$test\_site = '[http://portaltest/&#39](http://portaltest/&#39);

# open the IE browser  
$ie = Watir::IE.new

# print some comments  
puts "#Beginning of test: Test Portal"  
puts "Step 1: go to the test site: " + $test\_site  
$ie.goto($test\_site)

output:  
#Beginning of test: Test Portal  
Step 1: go to the test site: [http://portaltest/](http://portaltest/)  
D:/ruby/lib/ruby/site\_ruby/1.8/watir.rb:1136:in `set\_defaults':  
undefined method `frames' for nil:NilClass (NoMethodError)  
&nbsp;&nbsp;from D:/ruby/lib/ruby/site\_ruby/1.8/watir.rb:1436:in `call'  
&nbsp;&nbsp;from D:/ruby/lib/ruby/site\_ruby/1.8/watir.rb:1436:in  
`run\_error\_checks'  
&nbsp;&nbsp;from D:/ruby/lib/ruby/site\_ruby/1.8/watir.rb:1435:in `each'  
&nbsp;&nbsp;from D:/ruby/lib/ruby/site\_ruby/1.8/watir.rb:1435:in  
`run\_error\_checks'  
&nbsp;&nbsp;from D:/ruby/lib/ruby/site\_ruby/1.8/watir.rb:1419:in `wait'  
&nbsp;&nbsp;from D:/ruby/lib/ruby/site\_ruby/1.8/watir.rb:1254:in `goto'  
&nbsp;&nbsp;from Newscript.rb:17

and some time with different script am getting following error

D:/ruby/lib/ruby/site\_ruby/1.8/watir.rb:1237:in `method\_missing':  
document (WIN32OLERuntimeError)  
&nbsp;&nbsp;&nbsp;&nbsp;OLE error code:80004005 in \<Unknown\>  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\<No Description\>  
&nbsp;&nbsp;&nbsp;&nbsp;HRESULT error code:0x80020009  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Exception occurred. from  
D:/ruby/lib/ruby/site\_ruby/1.8/watir.rb:1237:in `title'  
&nbsp;&nbsp;from D:/ruby/lib/ruby/site\_ruby/1.8/watir.rb:1312:in  
`set\_window\_state'  
&nbsp;&nbsp;from D:/ruby/lib/ruby/site\_ruby/1.8/watir.rb:1291:in `maximize'  
&nbsp;&nbsp;from fina1l.rb:17:in `basic\_auth'  
&nbsp;&nbsp;from fina1l.rb:115

> **···**
>
> --  
> Posted via [http://www.ruby-forum.com/\](http://www.ruby-forum.com/%5C).

---

<div class="post-metadata">

**Author:** ![Jonas\_Pfenniger\_zimb](https://avatars.discourse-cdn.com/v4/letter/j/c5a1d2/32.png) [@Jonas\_Pfenniger\_zimb](https://rubytalk.org/u/Jonas_Pfenniger_zimb)\
**Post date:** [14 January 2011 20:00 UTC](https://rubytalk.org/t/need-assistance-in-error/61458/2 "2011-01-14T20:00:30Z")

</div>

Hi Balabaskaran,

it is really hard to tell because I don't use windows, but here are  
some steps you can take:

\* Did you try to ask your question on the Watir google group ? They  
maybe have a better idea of what is happening. See  
[http://groups.google.com/group/watir-general](http://groups.google.com/group/watir-general)

\* Try upgrading ruby. [http://rubyinstaller.org/](http://rubyinstaller.org/) is a really wonderful  
windows package. Maybe stick with 1.8.7 if you already have some code  
base. These kind of errors appear either because you passed the wrong  
type of argument or method, or because the API is not compatible with  
your current version of ruby.

Hope this help,  
&nbsp;&nbsp;zimbatm

---

<div class="post-metadata">

**Author:** ![Balabaskaran\_Raghu](https://avatars.discourse-cdn.com/v4/letter/b/5fc32e/32.png) [@Balabaskaran\_Raghu](https://rubytalk.org/u/Balabaskaran_Raghu)\
**Post date:** [15 January 2011 08:16 UTC](https://rubytalk.org/t/need-assistance-in-error/61458/3 "2011-01-15T08:16:45Z")

</div>

Hi zimbatm,

I haven't posted this question to google watir group, I will post the  
questio there and see what turns out.

Thank you for you suggesstion.

Regards,  
Bala

> **···**
>
> --  
> Posted via [http://www.ruby-forum.com/](http://www.ruby-forum.com/).
