I have an app that detects when a file if changed on disk and pops up a modal dialog when this occurs asking the user if they want to load the new file. This works fine until the screen saver kicks in. If the modal dialog pops up after the screen saver kicks in, then the mouse is moved and the main form repaints, the modal dialog is behind the main form but has the focus.
You can get it back to the front with Alt-Tab, but it is confusing for users, as they don't know the pop-up is there and when they click on the main form they get a beep (as the hidden modal form has focus). They usually end up killing the task or the machine, even though they don't need to.
I've tried BringToFront anf fsStayOnTop. How can you force a form to the front when its owner is repainted after a screen save?