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. Tons of CDialog issue

Tons of CDialog issue

Scheduled Pinned Locked Moved C / C++ / MFC
cssasp-netdesignarchitecturehelp
5 Posts 2 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.
  • L Offline
    L Offline
    Llasus
    wrote on last edited by
    #1

    Hello and good day. I have an application which is composed of 35 CDialog classes. Now, I haven't really done this many dialogs before in a single application before; usually when it's just 10 or less I just do a DoModal to go to the next dialog. Then someone said that it is better to just have one main dialog class, then just re-create the dialog's appearance when shifting to another screen (since the top part of the dialog has always the same appearance and buttons except the title). I know that somehow this is better, as it will be removing some of the repeating parts of the dialog but I really don't have that much of an idea here. So can anyone give me suggestions on how to start this up? I am currently reading about design patterns (MVC) and looking if this applies to the application. But still I need some expert opinions here who can give me some light on this.. Thanks in advance. :)

    R 1 Reply Last reply
    0
    • L Llasus

      Hello and good day. I have an application which is composed of 35 CDialog classes. Now, I haven't really done this many dialogs before in a single application before; usually when it's just 10 or less I just do a DoModal to go to the next dialog. Then someone said that it is better to just have one main dialog class, then just re-create the dialog's appearance when shifting to another screen (since the top part of the dialog has always the same appearance and buttons except the title). I know that somehow this is better, as it will be removing some of the repeating parts of the dialog but I really don't have that much of an idea here. So can anyone give me suggestions on how to start this up? I am currently reading about design patterns (MVC) and looking if this applies to the application. But still I need some expert opinions here who can give me some light on this.. Thanks in advance. :)

      R Offline
      R Offline
      Rajesh R Subramanian
      wrote on last edited by
      #2

      You may try CtreePropSheet[^] or CTreePropSheetEx[^]. All your dialogs will be contained within a window and the user will be able to navigate through the dialogs easily.

      Nobody can give you wiser advice than yourself. - Cicero .·´¯`·->Rajesh<-·´¯`·. Codeproject.com: Visual C++ MVP

      L 1 Reply Last reply
      0
      • R Rajesh R Subramanian

        You may try CtreePropSheet[^] or CTreePropSheetEx[^]. All your dialogs will be contained within a window and the user will be able to navigate through the dialogs easily.

        Nobody can give you wiser advice than yourself. - Cicero .·´¯`·->Rajesh<-·´¯`·. Codeproject.com: Visual C++ MVP

        L Offline
        L Offline
        Llasus
        wrote on last edited by
        #3

        thanks for the help! i will try this but, is there any other way rather than importing this code in my application? sorry if i did not mention but I am specifically looking for a sort of process which I should do with my codes or rather an existing object within c++. again thank you for your help, I'll maybe import this if there is really no other possible way. thank you.

        R 1 Reply Last reply
        0
        • L Llasus

          thanks for the help! i will try this but, is there any other way rather than importing this code in my application? sorry if i did not mention but I am specifically looking for a sort of process which I should do with my codes or rather an existing object within c++. again thank you for your help, I'll maybe import this if there is really no other possible way. thank you.

          R Offline
          R Offline
          Rajesh R Subramanian
          wrote on last edited by
          #4

          Llasus wrote:

          sorry if i did not mention but I am specifically looking for a sort of process which I should do with my codes or rather an existing object within c++.

          If I understand it right, you want to redo something similar? :wtf: Why would you do it, when somebody has already done it? The classes I linked you to are built very well, presented to the community and are already being used by people. I suggested you to use it because it will enable you to build a more friendly and more easily manageable user interface. If you are worried only because your application is cluttered with lots and lots of dialog boxes and you don't know how to manage them together, then CTreePropSheet or CTreePropSheetEx are very good options.

          Llasus wrote:

          I'll maybe import this if there is really no other possible way.

          You see, there's a thing called code-reusability, which is one of the major advantages of OOP. Why don't you take full advantage of that? Making use of those classes will do good for you, because you are with a typical problem of having lots of dialogs and you don't know how to mend them together. By using either of those classes, you could also group dialogs that are closely related into a category. By all means, I will suggest you to at least try either of those classes once.

          L 1 Reply Last reply
          0
          • R Rajesh R Subramanian

            Llasus wrote:

            sorry if i did not mention but I am specifically looking for a sort of process which I should do with my codes or rather an existing object within c++.

            If I understand it right, you want to redo something similar? :wtf: Why would you do it, when somebody has already done it? The classes I linked you to are built very well, presented to the community and are already being used by people. I suggested you to use it because it will enable you to build a more friendly and more easily manageable user interface. If you are worried only because your application is cluttered with lots and lots of dialog boxes and you don't know how to manage them together, then CTreePropSheet or CTreePropSheetEx are very good options.

            Llasus wrote:

            I'll maybe import this if there is really no other possible way.

            You see, there's a thing called code-reusability, which is one of the major advantages of OOP. Why don't you take full advantage of that? Making use of those classes will do good for you, because you are with a typical problem of having lots of dialogs and you don't know how to mend them together. By using either of those classes, you could also group dialogs that are closely related into a category. By all means, I will suggest you to at least try either of those classes once.

            L Offline
            L Offline
            Llasus
            wrote on last edited by
            #5

            Rajesh R Subramanian wrote:

            If I understand it right, you want to redo something similar? Why would you do it, when somebody has already done it? The classes I linked you to are built very well, presented to the community and are already being used by people.

            no, actually I want to find another option or another way that I can do. Like I am reading about design patterns and looking for one that could be applicable to this problem. Sorry if I might have not clearly explained myself well. I appreciate that I now have one possible solution which is the CTreePropSheet but I just want to know if there would be other solutions. Certainly I won't attempt to redo this, unless I have lots of time, knowing it's already proven and tested by the community.

            Rajesh R Subramanian wrote:

            By all means, I will suggest you to at least try either of those classes once.

            Thanks and I will try this first thing tomorrow. But even with this, I would still like to know if there are any other possible solutions to my problem. greatly appreciate it. 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