# Need clarification about WIN32OLE.new

**URL:** <https://www.ruby-forum.com/t/need-clarification-about-win32ole-new/142076>\
**Category:** Ruby\
**Created:** [July 3, 2008, 8:57am UTC](https://www.ruby-forum.com/t/need-clarification-about-win32ole-new/142076 "2008-07-03T08:57:55Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jazzezravi](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/71e660/32.png) [@jazzezravi](https://www.ruby-forum.com/u/jazzezravi)\
**Post date:** [July 3, 2008, 8:57am UTC](https://www.ruby-forum.com/t/need-clarification-about-win32ole-new/142076/1 "2008-07-03T08:57:55Z")

</div>

Hi All,

is it possible or not ?

Program:

require “watir”

ie = WATIR::IE.new  
ie.visible=false  
ie.goto(“[http://blahblah.com](http://blahblah.com)”)

When i run this program initially

ie = WATIR::IE.new this line creating IE object. So i can able to see  
that window.  
After that only i can able to invisible the window.

But i want to create new ie window initially invisible mode.

My tries:

I tried to change the watir gem codings

//watir/ie.rb

def create\_browser\_window  
@ie = WIN32OLE.new(‘InternetExplorer.Application’  
end

I added a @ie.visible=false after  
@ie = WIN32OLE.new(‘InternetExplorer.Application’. but it was not  
working. so i decided to add code to WIN32OLE gem or plugin. But i  
can’t do it.

So simply my need is,

@ie = WIN32OLE.new(‘InternetExplorer.Application’

want to create a application in invisible mode.

Thank in Advance

Regards,  
P.Raveendran

> **[Raveendran](https://raveendran.wordpress.com)**
>
> Nothing is impossible...

---

<div class="post-metadata">

**Author:** ![jazzezravi](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/71e660/32.png) [@jazzezravi](https://www.ruby-forum.com/u/jazzezravi)\
**Post date:** [July 3, 2008, 6:24pm UTC](https://www.ruby-forum.com/t/need-clarification-about-win32ole-new/142076/2 "2008-07-03T18:24:02Z")

</div>

On Thu, Jul 3, 2008 at 1:54 AM, Raveendran J. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> ie.goto(“[http://blahblah.com](http://blahblah.com)”)  
> Try this:

$HIDE\_IE = true

---

<div class="post-metadata">

**Author:** ![jazzezravi](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/71e660/32.png) [@jazzezravi](https://www.ruby-forum.com/u/jazzezravi)\
**Post date:** [August 5, 2008, 1:29pm UTC](https://www.ruby-forum.com/t/need-clarification-about-win32ole-new/142076/3 "2008-08-05T13:29:58Z")

</div>

Bret P. wrote:

> On Thu, Jul 3, 2008 at 1:54 AM, Raveendran J. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
> wrote:
> 
> > ie.goto(“[http://blahblah.com](http://blahblah.com)”)  
> > Try this:
> 
> $HIDE\_IE = true

Hi Pettichord.

After a long gap i taken that task and finished it following way…

watir gem/new.rb

replace ie.visible = $HIDE\_IE to ie.visible != $HIDE\_IE

Thanks  
Regards,  
P.Raveendran  
RF,Chennai,

> **[Raveendran](https://raveendran.wordpress.com)**
>
> Nothing is impossible...
