TaskBar flash and progress display, and fsStayOnTop
- From: "Paul E. Schoen" <pstech@xxxxxxxxx>
- Date: Wed, 14 Feb 2007 16:13:21 -0500
Sorry to be a pest, but I have some questions in reference to my Autosave
automation client program PADSplus. Its purpose is to perform an autosave
of the open document of up to three instances of the application. When the
timer tick occurs, I do the following:
if Sender = Timer[1] then Item := 1
else if Sender = Timer[2] then Item := 2
else Item := 3;
Form1.WindowState := wsMinimized;
If SaveDialog[Item] = nil then
SaveDialog[Item] := TPADS2.Create( PADS2 );
SaveDialog[Item].Tag := Item;
SaveDialog[Item].Caption := 'Autosaving ' + PADSrec[Item].DocName;
SaveDialog[Item].Show;
Timer[Item].enabled := False;
The SaveDialog allows the user to cancel, or perform the autosave, either
of which re-enables the timer.
I have the SaveDialog.FormStyle := fsStayOnTop, and usually it stays
visible over other application windows, but eventually it will be covered,
and then it remains hidden unless I click on the PADSplus taskbar item, or
restore the window that was minimized. This also happens when I am just
editing the document with the application, so there is no notification, and
the autosave will not be done until the user makes the dialog reappear by
clicking the taskbar or restoring the form.
The help on fsStayOnTop indicates that another form of that style will
cause inconsistent behavior, and also that it is not advised to change the
style at runtime. I am creating an unused instance at startup, and then
creating more forms as needed. Is it possible to force the form to appear
by resetting one of its properties on a periodic timer tick, or releasing
and recreating it?
I would also like to be able to have the taskbar flash when one of the
Autosave dialogs needs to be serviced by the user. It would also be helpful
to display there a countdown to the next Autosave event. A www.Dogpile.com
search turned up http://www.delphicorner.f9.co.uk/articles/apps9.htm, which
should be possible to use with my D4, but I can't find any reference to the
TFlashWInfo type or the FlashWindowEx(FWinfo) method.
My code for the present version of this project is on my website at:
www.smart.net/~pstech/PADSplusCode.zip.
Thanks,
Paul
.
- Follow-Ups:
- Re: TaskBar flash and progress display, and fsStayOnTop
- From: Paul E. Schoen
- Re: TaskBar flash and progress display, and fsStayOnTop
- Prev by Date: Re: Problem freeing components with .free
- Next by Date: Re: Editor component
- Previous by thread: Problem freeing components with .free
- Next by thread: Re: TaskBar flash and progress display, and fsStayOnTop
- Index(es):