Hi everyone. I want to make my desktop window app blink (or flash) on the taskbar… I was reading this thread, but I could not find the answer --> https://forum.xojo.com/4935-make-a-window-flash.
Taking into account that 4 years have passed from that thread … is there any way to achieve this natively? In case it does not … how can it be achieved in windows, linux and mac?
I currently use windows 10 and xojo 2016R3
For windows:
https://msdn.microsoft.com/en-us/library/windows/desktop/ms679347(v=vs.85).aspx
See https://github.com/arbp/WFS type flashwindow into the search box.
thanks @ I have seen that link and I have not been able to make it work
https://github.com/arbp/WFS/search?utf8=?&q=flashwindow&type=
(that’s the direct declare if that helps)
Here is a working example from my Windows Declare book. It’s example 5.5 to flash a window in both 32-but and 64-bit mode.
//Convert the C++ function
Declare Function FlashWindow Lib "user32" Alias "FlashWindow" ( hwnd As Integer, bInvert As Boolean ) As Boolean
//Create a boolean variable
Dim IsSuccessful as Boolean
//Call the function
IsSuccessful = FlashWindow(Window1.Handle, True)
Place the above code in a push button action event, run the program and press the button to flash Window1.
P.S. Pardon spelling mistakes as I am writing this on my phone.
i dragged this folder into the ide…
…and get a lot of errors…
surely the library works great, but I do not realize how to use it (i know, my ignorance is epic)
the @Eugene Dakin code works great… equally, thank you all for your help
my doubt is that, according to this link -> , the name of the function is “FlashWindowEx”, but in the code of @Eugene Dakin the function is called “FlashWindow”, it lacks the “Ex”, but still works perfect, I wonder why?
Microsoft uses the “Ex” suffix to differentiate the “extended”/newer version of a function from the older version. You can use either one.
thanks @Andrew Lambert !