Re: bring application the top
You could bring the view to the front, but just calling the functions or you
could get the mainframe (AfxGetMainWnd()) if you want to pull the whole
program window to the front.
CWnd *pWnd = AfxGetMainWnd();
if(pWnd != NULL) {
// Do what you want here
}
Or you could just send a message to the mainframe tell it what to do instead
of calling functions for it depending on where the code is being called
from.
Tom
"Mark" <mark@intern.net> wrote in message
news:e9mkYDXHIHA.4592@TK2MSFTNGP02.phx.gbl...
Thanks,
Since I control the view, I want it to happen from the view .Do you know
how to get it invoked from view::OnMouseMove?
Thanks
Mark
"Tom Serface" <tom.nospam@camaswood.com> wrote in message
news:63737052-85CB-4751-AFA0-560CF957335A@microsoft.com...
You could call BringWindowToTop() and SetForegroundWindow() from your
mainframe code when you want this to happen. I've found it also works
for dialogs. Although, that doesn't keep some other application from
doing that to you subsequently.
Tom
"Mark" <mark@intern.net> wrote in message
news:OjTR%23KWHIHA.3600@TK2MSFTNGP06.phx.gbl...
I have single document application and I want to bring it to the top of
all windows(possibly with focus).
Is it possible and how?
Regards
Mark