Jump to content
Sign in to follow this  
t0ddie

why isnt this hiding?

Recommended Posts

why isnt this hiding the browser window?

Run("C:\Program Files\Mozilla Firefox\firefox.exe","",@SW_HIDE)

and more importantly, HOW do i hide it?


Valik Note Added 19 October 2006 - 08:38 AMAdded to warn level I just plain don't like you.

Share this post


Link to post
Share on other sites

this will do the trick

#include <GUIConstants.au3>

Run(@ProgramFilesDir & "\Internet Explorer\iexplore.exe www.xpcleanmenu.hostrocket.com")

WinWaitActive("")
Sleep(5000)
WinSetState( "", "", @SW_HIDE )

Sleep(5000)
WinSetState( "", "", @SW_SHOW)

good luck


NEWHeader1.png

Share this post


Link to post
Share on other sites

this will do the trick

True, but why does'nt it work with Run(). I've tested it with oter applications and it works. It seems, that Firefox ignores messages while starting up!??!

Cheers

Kurt


__________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *

Share this post


Link to post
Share on other sites

I believe Valik answered this a while back but I can't find the post, so I'll try and word it form memory :(.

When you use the @SW_XXXX macro's, you are asking the program if you can open it in that way. You are not forcing it, just asking politly, and the program may or may not let you do it, in this case... not.


qq

Share this post


Link to post
Share on other sites

this will do the trick

#include <GUIConstants.au3>

Run(@ProgramFilesDir & "\Internet Explorer\iexplore.exe www.xpcleanmenu.hostrocket.com")

WinWaitActive("")
Sleep(5000)
WinSetState( "", "", @SW_HIDE )

Sleep(5000)
WinSetState( "", "", @SW_SHOW)

Hi,

Forgive me for being a dummy, but 1: I'm assuming that there has to be some data stuck between the quotes in the WinWait(). 2: I don't understand the reason for the Sleep(). Doesn't it pause AutoIt and essentially just do nothing? So why would it be needed? 3: Is there an easy way to hide entirelly the program that is running? I would like to shield the process of an installation of an application.

TIA.


Heisenberg was probably right...

Share this post


Link to post
Share on other sites

Hi,

WinWaitActive("") is in fact, "last active" window :(

The sleep in this script is just as an example to show and hide the window.

Andre


What about Windows without using AutoIt ?It would be the same as driving a car without an steering Wheel!

Share this post


Link to post
Share on other sites

I believe Valik answered this a while back but I can't find the post, so I'll try and word it form memory :(.

When you use the @SW_XXXX macro's, you are asking the program if you can open it in that way. You are not forcing it, just asking politly, and the program may or may not let you do it, in this case... not.

<{POST_SNAPBACK}>

can it be forced then?

Valik Note Added 19 October 2006 - 08:38 AMAdded to warn level I just plain don't like you.

Share this post


Link to post
Share on other sites

I don't think so but as posted above, you can make a simple work around such as Valuater's.

WinSetState( "Your window title", "", @SW_HIDE )

qq

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...