When a user switches to another application while your application is doing a
time-consuming action, then you probably
want to notify the user that the action has ended. In Windows it's possible to let the taskbar-icon of your applcation flash.
Therefore you must declare two local external functions:Function uLong FlashWindow( uLong hWnd, Boolean bInvert ) Library "user32.dll"
next code in the Timer-event of your MDI- or mainwindow.
Timer( 0 )
When resetting the timer, it's possible that taskbar icon just 'blued up', so by calling FlasWindow with False, you make it inactive.
FlashWindow( Handle( this ), False )
Add also a function to your MDI- or Main-Window and call it (e.g.) of_IsActive()
public function Boolean of_IsActive()
( Handle( this ) = GetForegroundWindow() )
Put code in the RetrieveEnd-event of your datawindow to start timer-event, so:
If Not w_Frame.of_IsActive() Then w_frame.Timer( 0.5 )