Jump to content

@SW_MINIMIZE problem


 Share

Recommended Posts

Hi I'm trying to minimize my VirtualMachine Window when it is booting.

I don't want that is showed on screen the window of XP machine when it is loading but i have some difficult.

If i test using "The Gui of VirtualBox" --> Run("app64\VirtualBox.exe", "", @SW_MINIMIZE) It's ok, windows is minimized

but if i start Virtual Machine using its correct parameteres to execute, don't run:

; Script ONE

$DIR="C:\Program Files\MyProg\VirtualBox"

Run("app64\Virtualbox.exe --startvm ""WinXP""", $DIR, @SW_MINIMIZE)

The only way that i have found is running Virtual Machine

and test the state of window.

In this mode runs but the window appear again also if only for half second (about).

; Script TWO

$Title="WinXP [Running] - Oracle VM VirtualBox"

Run("app64\Virtualbox.exe --startvm ""WinXP""")

While WinGetState($Title)=0

WinSetState($Title, "", @SW_MINIMIZE)

wend

To increase to maximum speed to minimize window, better than Script Two, the only way is this

; Script THREE

Run("app64\Virtualbox.exe --startvm ""WinXP""")

sleep(670)

WinSetState("WinXP", "", @SW_MINIMIZE)

The result is that the window is showed only 0,1 .. 0,2 seconds, but always appear.

There is no way to MINIMIZED window without that it is showed before ??

I have proved testing with command

- WinExists

- WinGetTitle

but window always appear for few istants

Have some council to give me ??

Thanks

Link to comment
Share on other sites

Yes i have.S ame problem. It was my 1st step that i have considered,and only then i have proved also @SW_MINIMIZE but nothing to do.

The problem is generated from the options --startvm ""WinXP"" that i must add behind VirtualBox.exe into string command in order to start Virtual Machine

Link to comment
Share on other sites

just tested under XP with VirtualPC hdd located in my documents folder linked to VirtualBox program and this works just fine for me on VirtualBox

Run('C:Program FilesOracleVirtualBoxVirtualBox.exe --startvm "WinXP"', 'C:Program FilesOracleVirtualBox',@SW_MINIMIZE)

setting it to @SW_HIDE, win dont show but from Task Manager i can see process running so im assumming that @SW_HIDE is working 2.

youl notice that im using The full path of the program

i dont know how the things are done on win7 but telling program to run from

"C:Program FilesMyProgVirtualBox" if your path is (and you did not tupe in its full path) "app64Virtualbox.exe" is little discouraging and i'm afraid i don't understand what you're trying to achieve with them.

Edited by bogQ

TCP server and client - Learning about TCP servers and clients connection
Au3 oIrrlicht - Irrlicht project
Au3impact - Another 3D DLL game engine for autoit. (3impact 3Drad related)



460px-Thief-4-temp-banner.jpg
There are those that believe that the perfect heist lies in the preparation.
Some say that it’s all in the timing, seizing the right opportunity. Others even say it’s the ability to leave no trace behind, be a ghost.

 
Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...