ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE.

Main Area and Open Discussion > Living Room

how to get to a dialog window that won't come into focus by using the keyboard?

<< < (7/8) > >>

nudone:
oh right. that's intersting though. if WiLMA can disable things then that does open up possibilities.

cranioscopical:
oh right. that's intersting though. if WiLMA can disable things then that does open up possibilities.
-nudone (May 14, 2010, 12:14 PM)
--- End quote ---
Oh dear, sorry again, I must learn to express myself better.  :-[
I don't think WiLMA will do that, so you'd just call WiLMA by launching something (of your own): step 1 stop AWM, step 2 start WiLMA -- batch file, a line or two of ahk, whatever. You'll need to see if you need that, and what if any interactions you have on your system, and what works best for you.

nudone:
oooohhh. i see. well, thanks for clarifying that.

lanux128:
this is a newer version of this script. the changes are ini file support for adding new windows/dialogs to be watched and tray menu customization. please give it a try.

nudone:
thanks very much, lanux128.

i've commented out the tooltip in the loop as it wouldn't stop floating around my cursor when it appeared.

is it a complicate addition to make the loop perform different actions depending on which window is activated?

currently it works fine for me - as the "Yes" button is always the one to click in the dialogs used. but i expect this will not always be the case.

here's the current script.


--- Code: AutoIt ---#Persistent#SingleInstance force#NoEnv;#NoTrayIconSetBatchLines, -1SetTitleMatchMode, 2    ; partial title matchSetWorkingDir, %A_ScriptDir%DetectHiddenWindows, Off ; they are hidden for a reason.. Gosub, Get_INI              ; go to INI sectionIfExist, %TrayIcon%         ;TrayMenu Customisation  Menu, Tray, Icon, %TrayIcon%  Menu, Tray, Tip, Activate the specified window/dialog whenever it appears.SetTimer, ActivateMe, 500   ; timer starts - increase or decrease the value as necessaryReturn ActivateMe:;parse and auto-activateLoop, Parse, WatchThese, |{        ;Tooltip, %A_LoopField%        IfWinExist %A_LoopField%        {                    WinActivate    ;do something here like press the ok button                ControlClick, Yes                ;sleep for a while - good for cpu cycle                Sleep, 2000        }}Return Get_INI:If (!FileExist("ActivateDialogs.ini")) ;if the ini file doesn't exist, create it with the info below{        FileAppend, [Settings]`nWatchThese=File has changed ahk_class #32770|Delete Shortcut ahk_class #32770`nTrayIcon=Application-warn.ico, ActivateDialogs.ini} IniRead,WatchThese,ActivateDialogs.ini,Settings,WatchTheseIniRead,TrayIcon,ActivateDialogs.ini,Settings,TrayIcon Return

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version