Archive: Need some help with Exec / ExecWait


Need some help with Exec / ExecWait
How can I run uninstaller or other .exe file
and hide current installer window until I finish with the new exec... ?


You could execute HideWindow before calling ExecWait to hide the installer, and then use BringToFront afterwards to show the installer again.


Can't hide it

Originally posted by Sunjammer
You could execute HideWindow before calling ExecWait to hide the installer, and then use BringToFront afterwards to show the installer again.
I tried it (also the commented stuff)
;  Push ${MUI_TEMP1}
;
; FindWindow ${MUI_TEMP1} "#32770" 0 $HWNDPARENT
;
; ShowWindow ${MUI_TEMP1} ${SW_HIDE}
; SendMessage ${MUI_TEMP1} ${WM_SHOWWINDOW} 0 ${SW_HIDE}

HideWindow
ExecWait "$1"
; ExecShell open "$1"
BringToFront

; ShowWindow ${MUI_TEMP1} ${SW_NORMAL}
; SendMessage ${MUI_TEMP1} ${WM_SHOWWINDOW} 0 ${SW_NORMAL}
;
; Pop ${MUI_TEMP1}

But still - it shows the called exe (uninstaller.exe) win
but DOES NOT hide the current (setup) window
(maybe it has the same HWND ?)

P.S.
I do it on .onInit

Um, but onInit, the installer dialog won't have shown yet - so how can you hide it?

-Stu :o


...
Quote:


Well, it will show coz the Exec functions wont wait and show them both
(I know - I'm a special case :-)

Anyway - Good news - I finally managed 2 do it
Yieeeha

What a great source.

I'm just about to give my two full days work modern-UI script...
10Q all.

Originally posted by Afrow UK
Um, but onInit, the installer dialog won't have shown yet - so how can you hide it?

-Stu :o