Sign in to follow this  
Followers 0
DeathRow

! RunWait command PROBLEM !

24 posts in this topic

I discovered that RunWait Flags DOESN'T WORK with the FireFox Browser :bye: !

Example: I want to open Firefox minimized,and doesn't work :

RunWait("C:\Program Files\Mozilla Firefox\firefox.exe" , " ", @SW_MINIMIZE )

Doesn't work with ShellExecute either :oops: .

How to open it minimized ?

Share this post


Link to post
Share on other sites



space in the working directory parameter

No , I don't use it with the spaces ,but even with that it doesn't matter. But the command works,but the @flag doesn't seem to work with Firefox ! :oops:

I tried with another program and it worked but why it doesn't work with the browser ??

Share this post


Link to post
Share on other sites

what does @flag mean? anyway this will start Firefox in a minimized state, I have just tested it works fine,

RunWait(@ProgramFilesDir & "Mozilla Firefoxfirefox.exe", "", @SW_MINIMIZE)

The @flag means what flag to put like @SW_MINIMIZE,@SW_RESTORE

o.O It really works for you ??? How ?? I runned the above script, it opens the firefox window home page,but NOT MINIMIZED ! :oops:

NOTE: My home page opens everytime in a MAXIMIZED state,du no if this can be the problem....

Share this post


Link to post
Share on other sites

No , I don't use it with the spaces

If you are using the command you posted. You DO have a space.

RunWait("C:\Program Files\Mozilla Firefox\firefox.exe" , " ", @SW_MINIMIZE )
                                                          ^
                                                      right here


Whenever someone says "pls" because it's shorter than "please", I say "no" because it's shorter than "yes".

Share this post


Link to post
Share on other sites

If you are using the command you posted. You DO have a space.

I used this :
RunWait(@ProgramFilesDir & "Mozilla Firefoxfirefox.exe", "", @SW_MINIMIZE)
and ,fantastic, it DIDN'T WORKED :oops: . The homepage is opening but it seems that the MINIMIZE flag has no effect

Share this post


Link to post
Share on other sites

Interesting. I got it to work once, but not again. It seems to open Firefox and minimize it like it should, but then Firefox decides it wants to show itself and pops back up.


Whenever someone says "pls" because it's shorter than "please", I say "no" because it's shorter than "yes".

Share this post


Link to post
Share on other sites

#10 ·  Posted (edited)

Has not worked for me since version 3.xx (firefox)

Oh sad :oops: But why ?

But I observed why it doesn work, because Firefox is starting everytime MAXIMIZED and has no effect to a MAXIMIZED page, so first you need to reposition or move or whatever the window manually, then you can send whatever commands to it :/

EDIT: Lol no its not because its MAXIMIZED,its because Firefox( like other programs ) blocks this function

Edited by DeathRow

Share this post


Link to post
Share on other sites

I need to see those numbers

$FileVersion = FileGetVersion(@ProgramFilesDir & "Mozilla Firefoxfirefox.exe", "FileVersion")
$ProductVersion = FileGetVersion(@ProgramFilesDir & "Mozilla Firefoxfirefox.exe", "ProductVersion")
$BuildID = FileGetVersion(@ProgramFilesDir & "Mozilla Firefoxfirefox.exe", "BuildID")
ConsoleWrite($FileVersion & @CRLF & $ProductVersion & @CRLF & $BuildID & @CRLF)

Share this post


Link to post
Share on other sites

11.0

11.0

20120312181643

Share this post


Link to post
Share on other sites

OK. Got it. I can consistently get it to open minimized. The trick is... before closing Firefox you need to close all open tabs. There will be one tab open titled "New Tab" when you close Firefox. When running the open FF minimized script from this status, it will open minimized (for me at least).


Whenever someone says "pls" because it's shorter than "please", I say "no" because it's shorter than "yes".

Share this post


Link to post
Share on other sites

OK. Got it. I can consistently get it to open minimized. The trick is... before closing Firefox you need to close all open tabs. There will be one tab open titled "New Tab" when you close Firefox. When running the open FF minimized script from this status, it will open minimized (for me at least).

Hmm... every time when I open firefox with the script, the first page is firefox google.I don't have any 'New Tab' :/

Share this post


Link to post
Share on other sites

#15 ·  Posted (edited)

In Firefox, close all the tabs that are open except for the final tab which will appear and be named "New Tab". With just the "New Tab" open, close Firefox. Now run the script and it will open Firefox minimized. While minimized, Firefox will open google, but should stay minimized.

Edited by JohnQSmith

Whenever someone says "pls" because it's shorter than "please", I say "no" because it's shorter than "yes".

Share this post


Link to post
Share on other sites

In Firefox, close all the tabs that are open except for the final tab which will appear and be named "New Tab". With just the "New Tab" open, close Firefox. Now run the script and it will open Firefox minimized. While minimized, Firefox will open google, but should stay minimized.

Yes I see its opening minimized,but try this :

First open Firefox manually, maximize it manually !, then close it with your new method, then try to open it minimized via the script. Tell me if it worked now ?

Share this post


Link to post
Share on other sites

Tell me if it worked now ?

Nope. Opens maximized.

Whenever someone says "pls" because it's shorter than "please", I say "no" because it's shorter than "yes".

Share this post


Link to post
Share on other sites

Nope. Opens maximized.

Yep it works only if its not closed maximized.

But why doesn't work ?? How can I make it to minimize if its maximized ?

Share this post


Link to post
Share on other sites

#20 ·  Posted (edited)

Just set it after its open

WinSetState()

It doesn't work even if I try to set its position !!

Run("C:Program FilesMozilla Firefoxfirefox.exe")
WinSetState("Start Page","",@SW_MINIMIZE)
Edited by DeathRow

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  
Followers 0