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. Creating View without document?

Creating View without document?

Scheduled Pinned Locked Moved C / C++ / MFC
c++question
5 Posts 4 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.
  • P Offline
    P Offline
    prasanth_mv
    wrote on last edited by
    #1

    Hi, Is it possible to create a view (In MFC MDI app)without document as follows? CMultiDocTemplate* pDocTemplate = new CMultiDocTemplate(IDR_CheckTYPE, NULL, RUNTIME_CLASS(CChildFrame), RUNTIME_CLASS(CCheckView)); I mean, passing NULL for the document runtimeclass and use pDocTemplate->CreateNewFrame(). Thanks, Prasanth

    M L P 3 Replies Last reply
    0
    • P prasanth_mv

      Hi, Is it possible to create a view (In MFC MDI app)without document as follows? CMultiDocTemplate* pDocTemplate = new CMultiDocTemplate(IDR_CheckTYPE, NULL, RUNTIME_CLASS(CChildFrame), RUNTIME_CLASS(CCheckView)); I mean, passing NULL for the document runtimeclass and use pDocTemplate->CreateNewFrame(). Thanks, Prasanth

      M Offline
      M Offline
      Maximilien
      wrote on last edited by
      #2

      Why you do not want to use the CDocument?

      I'd rather be phishing!

      1 Reply Last reply
      0
      • P prasanth_mv

        Hi, Is it possible to create a view (In MFC MDI app)without document as follows? CMultiDocTemplate* pDocTemplate = new CMultiDocTemplate(IDR_CheckTYPE, NULL, RUNTIME_CLASS(CChildFrame), RUNTIME_CLASS(CCheckView)); I mean, passing NULL for the document runtimeclass and use pDocTemplate->CreateNewFrame(). Thanks, Prasanth

        L Offline
        L Offline
        Lost User
        wrote on last edited by
        #3

        What happens when you try it?

        1 Reply Last reply
        0
        • P prasanth_mv

          Hi, Is it possible to create a view (In MFC MDI app)without document as follows? CMultiDocTemplate* pDocTemplate = new CMultiDocTemplate(IDR_CheckTYPE, NULL, RUNTIME_CLASS(CChildFrame), RUNTIME_CLASS(CCheckView)); I mean, passing NULL for the document runtimeclass and use pDocTemplate->CreateNewFrame(). Thanks, Prasanth

          P Offline
          P Offline
          ptse
          wrote on last edited by
          #4

          Yes, I do it all the time. - basically, the "View" will not be attached to the derived object class of (CDocument). - the attached derived (CDocument) object is intended to update the View when the derived object changes.

          P 1 Reply Last reply
          0
          • P ptse

            Yes, I do it all the time. - basically, the "View" will not be attached to the derived object class of (CDocument). - the attached derived (CDocument) object is intended to update the View when the derived object changes.

            P Offline
            P Offline
            prasanth_mv
            wrote on last edited by
            #5

            Thanks!

            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