The WinFlash function can be used to catch the attention of the user. The flashing effect is similar to a window losing and regaining focus.
|Title||The title of the window.||Required|
|Text||The text of the window to read.||Optional|
|Flashes||Nomber of time to flash. Default is 4.||Optional|
|Delay||Delay in milliseconds. Default is 500.||Optional|
When to use it
If you have automated an install process with AutoIt, and you want to be able to easily tell when a computer is done, without using sound. Then WinFlash could be used in a loop, to show that the process has been completed – there are many other ways to do this though.
WinFlash is more eye candy, and its hard to imagine where its use might be considered proper.
The following example script first opens notepad, then stores its window handle in a variable for later reference, and then it runs the WinFlash function, creating the flashing effect.
Run("notepad.exe") ; Saves the window handle $hWnd = WinWait("[CLASS:Notepad]", "", 10) ; Flashes the window WinFlash($hWnd, "", 4, 200)