Not exactly sure what your are trying to do,
but WIN.SetFocus(arg(2)) isn't a correct call.
Use: WIN.Show(arg(2))
Best to only use WIN.SetFocus(h) with handles from h=WIN.GetFocus.
Possibly use:
IF(arg(1)==3 && (arg(3)=="#32770" || arg(4)=="Information"))DO
WIN.Show(arg(2))
WIN.OnTop(arg(2), 1)
/*
; HookWindowEvents is called before some windows are ready
; to be shown, may have to give the window time to do its
; processing.
Event.CreateMS(500,1,"WIN.Show(" ++ arg(2)++ ")"++ ;;+
ESC(?"\r", ?"\")++ "WIN.OnTop(" ++ arg(2)++ ",1)")
*/
QUIT
ENDIF
> I'm using this script because, for some reason,
> Information windows and regsrvr32 dialog boxes will appear
> behind other windows, locking up various applications
> until I alt-tab to the hidden window.
The above maybe due to another HookWindowEvents or AutoRun error.
Add the following to the first line of your HookWindowEvents and
AutoRun commandlist and set GLOBAL gWindowEvents="OFF" and
see if this condition still exists.
[0]
Label = *
LCmd1 = IF(gWindowEvents=="OFF")
LCmd2 = QUIT
Hopefully I'm on the right track for you...
Ted
--- In [email protected], "Gardner, Paul G." wrote:
>
> I have a slight problem with the following
> HookWindowsEvent script:
>
> static SetFocusRun
>
> ;This is for info windows("Information"),
> or the regsrvr32 message dialogs (#32770)
> If ((arg(1) eq 5) and ((arg(4) eq "Information") or ;;+
> (arg(3) eq "#32770") ) ) do
> if (SetFocusRun eq 0) do
> SetFocusRun = 1
> win.ontop(arg(2))
> win.setfocus(arg(2))
> else
> SetFocusRun = 0
> endif
> endif
>
> Randomly, when I have this enabled, active windows will
> start flickering, esp PP config windows. Once a window
> starts flickering, it won't take mouse clicks, only ESC
> and Enter keys.
>
> ...
>
> Paul
------------------------ Yahoo! Groups Sponsor --------------------~-->
Most low income households are not online. Help bridge the digital divide today!
http://us.click.yahoo.com/cd_AJB/QnQLAA/TtwFAA/JV_rlB/TM
--------------------------------------------------------------------~->
Attention: PowerPro's Web site has moved: http://www.ppro.org
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/power-pro/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/