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. tab controls (is there a restriction on the number of edit boxes in a dialog box?)

tab controls (is there a restriction on the number of edit boxes in a dialog box?)

Scheduled Pinned Locked Moved C / C++ / MFC
helpquestion
8 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.
  • U Offline
    U Offline
    User 837914
    wrote on last edited by
    #1

    hi.. i have a problem here. I am making use of a tab control in a dialog box. Since I have 3 pages which all require edit boxes, i will need to have overlapping ones (in order to ensure that each tab page gets a edit box of its own). However, i couldn't add edit boxes afer some time. can anyone enlighten me? is there a restriction to the number of edit boxes that could be added? is the way i do things correct? as in making edit boxes overlap each other so that they will be displayed correspondingly (in correct position) in the various tabs correctly. Hope You guys can help me out on this!!! Thanks a lot!

    C D 2 Replies Last reply
    0
    • U User 837914

      hi.. i have a problem here. I am making use of a tab control in a dialog box. Since I have 3 pages which all require edit boxes, i will need to have overlapping ones (in order to ensure that each tab page gets a edit box of its own). However, i couldn't add edit boxes afer some time. can anyone enlighten me? is there a restriction to the number of edit boxes that could be added? is the way i do things correct? as in making edit boxes overlap each other so that they will be displayed correspondingly (in correct position) in the various tabs correctly. Hope You guys can help me out on this!!! Thanks a lot!

      C Offline
      C Offline
      Carlos Antollini
      wrote on last edited by
      #2

      Use the each tabl like an idependient Dialog. For this you must to use CPropertySheet and CPropertyPage... Best Reagrds Carlos Antollini Do you know piFive[^] ?

      U 1 Reply Last reply
      0
      • U User 837914

        hi.. i have a problem here. I am making use of a tab control in a dialog box. Since I have 3 pages which all require edit boxes, i will need to have overlapping ones (in order to ensure that each tab page gets a edit box of its own). However, i couldn't add edit boxes afer some time. can anyone enlighten me? is there a restriction to the number of edit boxes that could be added? is the way i do things correct? as in making edit boxes overlap each other so that they will be displayed correspondingly (in correct position) in the various tabs correctly. Hope You guys can help me out on this!!! Thanks a lot!

        D Offline
        D Offline
        David Crow
        wrote on last edited by
        #3

        azure33 wrote: is there a restriction to the number of edit boxes that could be added? In the past, the resource editor was limited to 255 controls. Whether that is still the case or not, I do not know. I've never been in the position to require that many. Adding the controls dynamically is limitless, I think.


        A rich person is not the one who has the most, but the one that needs the least.

        1 Reply Last reply
        0
        • C Carlos Antollini

          Use the each tabl like an idependient Dialog. For this you must to use CPropertySheet and CPropertyPage... Best Reagrds Carlos Antollini Do you know piFive[^] ?

          U Offline
          U Offline
          User 837914
          wrote on last edited by
          #4

          Sorrie right now what i'm not using CPropertySheet and CPropertyPage. Is it true that using tabs will always necessary need to use them? So do i just need to modify my code or redo it entirely?Since my tabs are done in a overlapping fashion (do you get what i mean?) I hope I don't have to redo everything, cos it can be pretty tedious. any hints on how to go about doing that??? Thanks for your help!

          C 1 Reply Last reply
          0
          • U User 837914

            Sorrie right now what i'm not using CPropertySheet and CPropertyPage. Is it true that using tabs will always necessary need to use them? So do i just need to modify my code or redo it entirely?Since my tabs are done in a overlapping fashion (do you get what i mean?) I hope I don't have to redo everything, cos it can be pretty tedious. any hints on how to go about doing that??? Thanks for your help!

            C Offline
            C Offline
            Carlos Antollini
            wrote on last edited by
            #5

            Yes, I know that is a very hard work.... If you want you can use the tabctrl with a lot of controls like editbox, labels, custom controls, in it, but is very dificult to use because you must to oredr the controls in the OnInitDialog. Other solution is to create the controls in OnInitDialog. When you feel that you are going crazy, it's better to use Property Sheet and Property Pages, because you will have each control in its dialog.... Each Dialog that will be a tab must be derived from CPropertyPage and not from CDialog. Then When you need to principal dialog, with all the dialogs in it, you must to use the CPropertySheet class and use the funcion AddPage for add each dialog in the Property Sheet... Regards Carlos Antollini Do you know piFive[^] ?

            U 1 Reply Last reply
            0
            • C Carlos Antollini

              Yes, I know that is a very hard work.... If you want you can use the tabctrl with a lot of controls like editbox, labels, custom controls, in it, but is very dificult to use because you must to oredr the controls in the OnInitDialog. Other solution is to create the controls in OnInitDialog. When you feel that you are going crazy, it's better to use Property Sheet and Property Pages, because you will have each control in its dialog.... Each Dialog that will be a tab must be derived from CPropertyPage and not from CDialog. Then When you need to principal dialog, with all the dialogs in it, you must to use the CPropertySheet class and use the funcion AddPage for add each dialog in the Property Sheet... Regards Carlos Antollini Do you know piFive[^] ?

              U Offline
              U Offline
              User 837914
              wrote on last edited by
              #6

              Yeah!! Thanks a lot for your help!!:rose: i know that I have to make use of CPropertySheet etc but most of the books i referred to , dont give me any information on how to go about doing tabs at all... :((:confused: Any good websites to recommend? Hope i can manage to complete it on time. Thank you very much!!!!!!!!!!! :)

              C 1 Reply Last reply
              0
              • U User 837914

                Yeah!! Thanks a lot for your help!!:rose: i know that I have to make use of CPropertySheet etc but most of the books i referred to , dont give me any information on how to go about doing tabs at all... :((:confused: Any good websites to recommend? Hope i can manage to complete it on time. Thank you very much!!!!!!!!!!! :)

                C Offline
                C Offline
                Carlos Antollini
                wrote on last edited by
                #7

                I was looking here in CP, but each article about PropertySheet and PropertyPage are about special implementacion. I pasted you a lines of code..... Trie to start with it, and then read in MDSN.... Don't worry is very easy.... Rememeber: each dialog must be derived from CPropertyPage, not from CDialog CPropertySheet dlgProperties("Properties", this); CMyPropertieDlg dlg1; //this dialog is a property page. CMyPropertieDlg dlg2; //this dialog is a property page. dlgProperties.AddPage(&dlg1); dlgProperties.AddPage(&dlg2); dlgProperties.m_psh.dwFlags |= PSH_NOAPPLYNOW; if(dlgProperties.m_psh.dwFlags & PSH_HASHELP) dlgProperties.m_psh.dwFlags ^= PSH_HASHELP; dlg1.m_strCubeName = m_strCubeName; dlg1.m_strCatalogName = strCatalogName; dlg1.m_strCreatedOn = strCreatedOn; dlg2.m_strLastUpdate = strDate; dlg2.m_strDescription = strDescription; if(dlgProperties.DoModal() != IDCANCEL) return; Regards Carlos Antollini Do you know piFive[^] ?

                A 1 Reply Last reply
                0
                • C Carlos Antollini

                  I was looking here in CP, but each article about PropertySheet and PropertyPage are about special implementacion. I pasted you a lines of code..... Trie to start with it, and then read in MDSN.... Don't worry is very easy.... Rememeber: each dialog must be derived from CPropertyPage, not from CDialog CPropertySheet dlgProperties("Properties", this); CMyPropertieDlg dlg1; //this dialog is a property page. CMyPropertieDlg dlg2; //this dialog is a property page. dlgProperties.AddPage(&dlg1); dlgProperties.AddPage(&dlg2); dlgProperties.m_psh.dwFlags |= PSH_NOAPPLYNOW; if(dlgProperties.m_psh.dwFlags & PSH_HASHELP) dlgProperties.m_psh.dwFlags ^= PSH_HASHELP; dlg1.m_strCubeName = m_strCubeName; dlg1.m_strCatalogName = strCatalogName; dlg1.m_strCreatedOn = strCreatedOn; dlg2.m_strLastUpdate = strDate; dlg2.m_strDescription = strDescription; if(dlgProperties.DoModal() != IDCANCEL) return; Regards Carlos Antollini Do you know piFive[^] ?

                  A Offline
                  A Offline
                  Anonymous
                  wrote on last edited by
                  #8

                  hello!!!! I have finally understood what it means to use CPropertyPage and CPropertySheet... But then I realised that I couldn't display the tabbed page after adding a certain number of combo boxes...... I'm going crazy. How come does a problem with displaying the combo boxes?? 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