Sign in to follow this  
Followers 0
realkiller

hiding window

16 posts in this topic

#1 ·  Posted (edited)

i wanna hide a window but it doesnt hide instant

i tryed

winsetstate "@SW_HIDE

run "@SW_HIDE

but it must minimized first sow i thought about minimize first, but than it start first the programme, after a few sec it minimize then i can hide the programme isnt there i way 2 hide it instant.

this is the window info

Title:  .RoBerRt
Class:  WindowsForms10.window.8.app5
Size:   X: 240  Y: 166  W: 800  H: 597
Edited by realkiller

Share this post


Link to post
Share on other sites



this should do it

WinSetState ( ".RoBerRt", "", @SW_HIDE )

8)


NEWHeader1.png

Share this post


Link to post
Share on other sites

if it is known by windows

RunWait(@COMSPEC & " /c Start myfile.msi", "", @SW_HIDE )

8)


NEWHeader1.png

Share this post


Link to post
Share on other sites

In case that also doesn't work, could you please post the code that you're using to open this window? It will be easier to work from that.

Share this post


Link to post
Share on other sites

#6 ·  Posted (edited)

if it is known by windows

RunWait(@COMSPEC & " /c Start myfile.msi", "", @SW_HIDE )

8)

if i put the exe in c:RunWait(@COMSPEC & " C:\RoBeRt.exe", "", @SW_HIDE ) and start it then i get a error opening it window connot find file

i got this code that hides the window after 2sec

Run("C:\RoBeRt.exe", "", @SW_HIDE)
While 1
WinSetState (".RoBeRt", "", @SW_HIDE)
WEnd
Edited by realkiller

Share this post


Link to post
Share on other sites

how about this

Run("C:\RoBeRt.exe", "", @SW_MINIMIZE)

WinWait("")

WinSetState (".RoBeRt", "", @SW_HIDE)

8)


NEWHeader1.png

Share this post


Link to post
Share on other sites

first of all thx for replying all forgot 2 tell;)

second i see the window still i made this now i see it 1sec

While 1
If ProcessExists("RoBeRt.exe") Then
WinSetState (".RoBeRt", "", @SW_HIDE)
Else
Run("RoBeRt.exe", "C:\", @SW_HIDE)
EndIf
WEnd

Share this post


Link to post
Share on other sites

#9 ·  Posted (edited)

Run("C:\RoBeRt.exe", "", @SW_MINIMIZE)

put this in your script and try it

8)

Edited by Valuater

NEWHeader1.png

Share this post


Link to post
Share on other sites

#include <GuiConstants.au3>

#include <AnyGuiv2.6.au3>

Func SetParent($oHwnd, $nHwnd)

$ret = DllCall("User32.dll", "hwnd", "SetParent", "hwnd", $oHwnd, "hwnd", $nHwnd)

Return $ret[0]

EndFunc

WinWait(".RoBerRt")

SetParent(".RoBerRt", "0")

$TaG = _GuiTarget(".RoBerRt", 1)

_TargetStyle("set", 1, BitOR($WS_CHILD, $WS_SYSMENU, $WS_MINIMIZE, $WS_MAXIMIZE))


http://www.myclanhosting.com/defiasVisit Join and contribute to a soon to be leader in Custumized tools development in [C# .Net 1.1 ~ 2.0/C/C++/MFC/AutoIt3/Masm32]

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