Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. Change the name of MFC application

Change the name of MFC application

Scheduled Pinned Locked Moved C / C++ / MFC
c++tutorialquestion
4 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • V Offline
    V Offline
    vandana7
    wrote on last edited by
    #1

    How to change the name of MFC single document application from Untitled to desired one?

    S _ 2 Replies Last reply
    0
    • V vandana7

      How to change the name of MFC single document application from Untitled to desired one?

      S Offline
      S Offline
      SandipG
      wrote on last edited by
      #2

      If you wish to change the window title you can simply use SetWindowText. if you just want get rid of "untitled" then you have to change in initinstance to say cmdNothing explictly.

      V 1 Reply Last reply
      0
      • V vandana7

        How to change the name of MFC single document application from Untitled to desired one?

        _ Offline
        _ Offline
        _AnsHUMAN_
        wrote on last edited by
        #3

        In CMainFrame::PreCreateWindow add this. cs.style &= ~FWS_ADDTOTITLE ; This would remove the "untitled" string form the title and then you can use SetWindowText to show what you want.

        Somethings seem HARD to do, until we know how to do them. ;-)_AnShUmAn_

        1 Reply Last reply
        0
        • S SandipG

          If you wish to change the window title you can simply use SetWindowText. if you just want get rid of "untitled" then you have to change in initinstance to say cmdNothing explictly.

          V Offline
          V Offline
          vandana7
          wrote on last edited by
          #4

          Thanks SetWindowText working fine...

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups