Sign in to follow this  
Followers 0
Steph

Set position of cmd window when using RunWait

3 posts in this topic

Hi All,

I unpack a zip file using the following:

RunWait(@ComSpec & " /c " & @TempDir & '\unzip.exe -o "' & @TempDir & '\' & $file & '" -d "' & $setupfiles & '"')

The DOS window pops up so the user can see something happening, however it appears to the left and above center. Is there are any way to get it to be nicely centered on the screen?

Thanks,

Steph

Share this post


Link to post
Share on other sites



Hi All,

I unpack a zip file using the following:

RunWait(@ComSpec & " /c " & @TempDir & '\unzip.exe -o "' & @TempDir & '\' & $file & '" -d "' & $setupfiles & '"')

The DOS window pops up so the user can see something happening, however it appears to the left and above center. Is there are any way to get it to be nicely centered on the screen?

Thanks,

Steph

Hello Steph,

just move the window that appears to the position you like with the autoit-command:

WinMove ( "title", "text", x-position, y-position) ;)

If you don't wan't to see the unzipping-window use:

#include <Process.au3>

$rc = _RunDos("start unzip.exe myarchivfile.zip /mypara")

Hope that helps :)

Greetings Carsten

Share this post


Link to post
Share on other sites

just move the window that appears to the position you like with the autoit-command:

WinMove ( "title", "text", x-position, y-position) :)

Thanks Carsten.

The problem is that because I'm using RunWait, the WinMove won't be done until the window has disappeared. I'm using RunWait so I can check the return status from the unzip command easily. I suspect I might have to use Run, then move the window, wait for the process to finish and then check the return status, though not sure how to do the last but yet.

... unless anybody else has any ideas.

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