60 IE instances is a lot. My first guess would be that IE7 uses more 
memory that IE6 and that therefore you can't create as many instances of 
it. You might consider getting more RAM to fix your problem.

Bret

Prince3105 wrote:
> Hi ALl,
>
> I am using below package.
>
> Watir version - 1.6.2
> Ruby version - 1.8.6
>
>
> I am using below code for log-in in batch running.
>
> require 'watir/ie'
> require 'watir/testcase'
> require 'watir/cookiemanager'
> require 'watir\contrib\enabled_popup'
> require 'watir/winClicker'
> require 'time'
> require 'win32/clipboard'
> include Win32
>
> Watir::CookieManager::WatirHelper.deleteSpecialFolderContents
> (Watir::CookieManager::WatirHelper::COOKIES)
> Watir::CookieManager::WatirHelper.deleteSpecialFolderContents
> (Watir::CookieManager::WatirHelper::INTERNET_CACHE)
>
>
> $url = "http://iic66/icomettest/iCometTest13/Login.aspx";
> $corp_id              = "admin"
> $corp_password  = "admin"
>
>
> def page_login(user_id, password)
>     @ie = Watir::IE.new
>     @ie.goto $url
>     @ie.maximize
>     @ie.bring_to_front
>
>     @ie.text_field(:id,"txtUserName").set user_id
>     @ie.text_field(:id,"txtPassword").set password
>     @ie.button(:id,"btnSubmit").click
> end
>
> class Test1 <Watir::TestCase
>   def test_a
>      page_login($corp_id, $corp_password)
>
>      # Some validation codes
>   end
> end
>
>
> since its a batch running, this function creates more than 60 IE
> instances in the test and i didn't face any issues.
>
> Last week i updated my IE version from 6 to 7 and ran the script
> again. But that function struggled in many times and didn't created
> some IE instances and threw below error. But the same code worked good
> in IE 6, but it failed in IE 7. It failed 5 times out of 62 new IE
> instances.
>
>  Error:
>    test_b(Test92):
>     WIN32OLERuntimeError: failed to create WIN32OLE object from
> `InternetExplorer.Application'
>     HRESULT error code:0x80004005
>       Unspecified error
>     c:/ruby/lib/ruby/gems/1.8/gems/watir-1.6.2/lib/watir/ie-class.rb:
> 167:in `initialize'
>     c:/ruby/lib/ruby/gems/1.8/gems/watir-1.6.2/lib/watir/ie-class.rb:
> 167:in `new'
>     c:/ruby/lib/ruby/gems/1.8/gems/watir-1.6.2/lib/watir/ie-class.rb:
> 167:in `create_browser_window'
>     c:/ruby/lib/ruby/gems/1.8/gems/watir-1.6.2/lib/watir/ie-class.rb:
> 91:in `_new_window_init'
>     c:/ruby/lib/ruby/gems/1.8/gems/watir-1.6.2/lib/watir/ie-class.rb:
> 87:in `initialize'
>     Stores&Spares_Masters.RB:196:in `new'
>     Stores&Spares_Masters.RB:196:in `page_login'
>     Stores&Spares_Masters.RB:424:in `test_b'
>
> So friends please take a look on my code, if any error in my code
> please correct it. If any workaround or some other ways are there
> please post it.
>
>
> Thanks,
>
> Prince3105
>
>
> >
>   


-- 
Bret Pettichord
Lead Developer, Watir, www.watir.com
Blog, www.io.com/~wazmo/blog
Twitter, www.twitter.com/bpettichord


--~--~---------~--~----~------------~-------~--~----~
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