CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    May 1999
    Posts
    44

    CFormView - Untiteld

    Hi!

    I created a SDI app and now I want to get rid of the "Untitled" in the caption bar, because this app
    will not open any files.
    So, please help me what I have to do...

    Bye
    Normen

    --
    apartis AG http://www.apartis.de
    Normen Mueller

  2. #2
    Guest

    Re: CFormView - Untiteld

    find you initinstance and before you show the window do a SetWindowText("whatever you want on the title bar"


  3. #3
    Join Date
    May 1999
    Posts
    44

    Re: CFormView - Untiteld

    It works.....

    Thanx
    Normen

    --
    apartis AG http://www.apartis.de
    Normen Mueller

  4. #4
    Join Date
    May 1999
    Location
    Farnborough, Hants, England
    Posts
    710

    Re: CFormView - Untiteld

    There is nothing wrong with the above solution, but if you want to conform to the MFC doc/view architecture as much as possible, what you should do instead is go to your main frame's PreCreateWindow() override and add this line at the start of the routine:

    cs.style &= ~FWS_ADDTOTITLE ;

    This is the preferred method for not displaying the loaded document name.



    --
    Jason Teagle
    [email protected]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured