[Lazarus] How to bring application to from (top)
Tommi Prami
groups.tprami at gmail.com
Fri Jul 8 13:38:00 CEST 2011
Hello,
I thought this would be very trivial, but I have tried very many
different things and searched from the net, and tried several code
snippets...
Here is some kind of list what I have tried so far...
1. Application.MainForm.BringToFront;
2. Application.RestoreStayOnTop(True);
3. MessageDlg('Come to papa', mtError, [mbOK], 0);
4. BringWindowToTop(Application.MainForm.Handle); // IE 5.5 related hack
SetForegroundWindow(Application.MainForm.Handle);
5.
Windows.MessageBox(
Self.Handle,
'Program already started',
'Program already started',
MB_SYSTEMMODAL or MB_SETFOREGROUND or MB_TOPMOST or
MB_ICONINFORMATION) ;
So far any of them have worked OK,,,
Main form can have modal children etc...
But I just cant pop the application to the surface :(
Is there any that would work... It should work on Windows Win32 and WiCE...
-TP-
More information about the Lazarus
mailing list