how to maximize an app just launched using RunProgram
Posted: Tue Feb 28, 2006 3:44 am
Hi
I'm building a launcher app - uses buttons to open Internet Explorer & other apps. I'm using RunProgram to launch these apps. I want to launch any app as maximized from the outset. Seems like there is no RunProgram switch to launch as maximized. So for IE, I am doing the following - but surely there is a better way? and of course this is IE specific. I'd like to be able to maximize any app that I launch this way.
Thanks to blueznl et al from this topic - that gave me the tip
viewtopic.php?t=18494
Thanks very much for any suggestion.
I'm building a launcher app - uses buttons to open Internet Explorer & other apps. I'm using RunProgram to launch these apps. I want to launch any app as maximized from the outset. Seems like there is no RunProgram switch to launch as maximized. So for IE, I am doing the following - but surely there is a better way? and of course this is IE specific. I'd like to be able to maximize any app that I launch this way.
Code: Select all
Procedure MaximizeIE()
h.l = GetTopWindow_(0)
While h <> 0
name.s = Space(513)
GetWindowText_(h,@name,512)
If FindString(name,"Internet Explorer",0)
Debug "name = " + name
ShowWindow_(h,#SW_SHOWMAXIMIZED)
EndIf
;
h = GetWindow_(h,#GW_HWNDNEXT)
Wend
EndProcedure
RunProgram("http://www.google.com/")
MaximizeIE()viewtopic.php?t=18494
Thanks very much for any suggestion.