You also need to get rid of FWS_ADDTOTITLE style:
BOOL CMainFrame::PreCreateWindow(CREATESTRUCT& cs)
{
cs.style &= ~FWS_ADDTOTITLE;
return CFrameWnd::PreCreateWindow(cs);
Quote:
}
or
ModifyStyle(FWS_ADDTOTITLE, 0); // After PreCreateWindow has been called.
--
Ajay Kalra
Microsoft VC++ MVP
Quote:
> AfxGetMainWnd()->SetWindowText("New Title");
> TFM3
> Note: spam-resistant e-mail address
> >Hi.
> >How do I change the text in the title bar of an MFC SDI application?
> >Thanks!
> >John