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
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. Items in a Combo Box..

Items in a Combo Box..

Scheduled Pinned Locked Moved C / C++ / MFC
question
19 Posts 4 Posters 1 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.
  • M Offline
    M Offline
    mpallavi
    wrote on last edited by
    #1

    Hello.. I am using a ComboBox to accept phone number from the user.. I want this phone numbers to be saved so that they can be used next time when the application is run.. How should i go about this? regards pallavi

    T N M 3 Replies Last reply
    0
    • M mpallavi

      Hello.. I am using a ComboBox to accept phone number from the user.. I want this phone numbers to be saved so that they can be used next time when the application is run.. How should i go about this? regards pallavi

      T Offline
      T Offline
      ThatsAlok
      wrote on last edited by
      #2

      mpallavi wrote: saved so that they can be used next time when the application is run. There no persistence COMBO box exist in Window MFC libaray. So you have to save it your own either in registry or a FILE and Display whenever needed :)

      "Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow

      cheers, Alok Gupta

      1 Reply Last reply
      0
      • M mpallavi

        Hello.. I am using a ComboBox to accept phone number from the user.. I want this phone numbers to be saved so that they can be used next time when the application is run.. How should i go about this? regards pallavi

        N Offline
        N Offline
        Nilesh K
        wrote on last edited by
        #3

        Have them written in a flat file when application is closing, And read them back to combo while initializing application.

        - Nilesh "Reading made Don Quixote a gentleman. Believing what he read made him mad" -George Bernard Shaw

        1 Reply Last reply
        0
        • M mpallavi

          Hello.. I am using a ComboBox to accept phone number from the user.. I want this phone numbers to be saved so that they can be used next time when the application is run.. How should i go about this? regards pallavi

          M Offline
          M Offline
          mpallavi
          wrote on last edited by
          #4

          Thank you.. I added a class that keeps track of the history.. i deleted the .clw file.. how do i regenerate it.. please tell me step by step.. I am coding for the first time in VC++/MFC.. Regards.. pallavi

          S N M 3 Replies Last reply
          0
          • M mpallavi

            Thank you.. I added a class that keeps track of the history.. i deleted the .clw file.. how do i regenerate it.. please tell me step by step.. I am coding for the first time in VC++/MFC.. Regards.. pallavi

            S Offline
            S Offline
            super
            wrote on last edited by
            #5

            Its simple... Open the workspace and go to menu view->Class Wizard. The following message will come The ClassWizard database _"yourprojectname.clw"_ does not exist. Would you like to build it from your source files? CLick "Yes" and Dialog box will appear .Then add all the files which you want to generate and then click "OK" cheers, Super ------------------------------------------ Too much of good is bad,mix some evil in it

            M 1 Reply Last reply
            0
            • S super

              Its simple... Open the workspace and go to menu view->Class Wizard. The following message will come The ClassWizard database _"yourprojectname.clw"_ does not exist. Would you like to build it from your source files? CLick "Yes" and Dialog box will appear .Then add all the files which you want to generate and then click "OK" cheers, Super ------------------------------------------ Too much of good is bad,mix some evil in it

              M Offline
              M Offline
              mpallavi
              wrote on last edited by
              #6

              Thank you.. Exactly where you stopped.. my problem begins.. All the files are listed .. I did "Add All" .. then i got a error messages saying ..couldn't open those files.. Which files should be regenerated.. OR ELSE TELL ME .. WHAT DOES .CLW CONTAIN???.. and why i couldn't add a memeber variable of a newly added class? regards pallavi

              T S 2 Replies Last reply
              0
              • M mpallavi

                Thank you.. I added a class that keeps track of the history.. i deleted the .clw file.. how do i regenerate it.. please tell me step by step.. I am coding for the first time in VC++/MFC.. Regards.. pallavi

                N Offline
                N Offline
                Nilesh K
                wrote on last edited by
                #7

                Check here[^]

                - Nilesh "Reading made Don Quixote a gentleman. Believing what he read made him mad" -George Bernard Shaw

                1 Reply Last reply
                0
                • M mpallavi

                  Thank you.. Exactly where you stopped.. my problem begins.. All the files are listed .. I did "Add All" .. then i got a error messages saying ..couldn't open those files.. Which files should be regenerated.. OR ELSE TELL ME .. WHAT DOES .CLW CONTAIN???.. and why i couldn't add a memeber variable of a newly added class? regards pallavi

                  T Offline
                  T Offline
                  ThatsAlok
                  wrote on last edited by
                  #8

                  Follow these steps:- 1.First Close down your Msdev and restart you computer. 2.Delete .ncw,.plg and .clw files if any 3.Now try to add Member Variable or Member Function using Class Wizard. this time Class Wizard will create corresponding .clw . 4. if step 3 fail, you have to manually add the Variable!

                  "Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow

                  cheers, Alok Gupta

                  1 Reply Last reply
                  0
                  • M mpallavi

                    Thank you.. Exactly where you stopped.. my problem begins.. All the files are listed .. I did "Add All" .. then i got a error messages saying ..couldn't open those files.. Which files should be regenerated.. OR ELSE TELL ME .. WHAT DOES .CLW CONTAIN???.. and why i couldn't add a memeber variable of a newly added class? regards pallavi

                    S Offline
                    S Offline
                    super
                    wrote on last edited by
                    #9

                    Ok U can do as Alok has said in his reply or also U skip the "Add ALL " part and try. I am having no problem with it cheers, Super ------------------------------------------ Too much of good is bad,mix some evil in it

                    1 Reply Last reply
                    0
                    • M mpallavi

                      Thank you.. I added a class that keeps track of the history.. i deleted the .clw file.. how do i regenerate it.. please tell me step by step.. I am coding for the first time in VC++/MFC.. Regards.. pallavi

                      M Offline
                      M Offline
                      mpallavi
                      wrote on last edited by
                      #10

                      Hey.. I could solve the problem at last.. My phone book is ready.. :) Thanks to all .. regards pallavi

                      T 1 Reply Last reply
                      0
                      • M mpallavi

                        Hey.. I could solve the problem at last.. My phone book is ready.. :) Thanks to all .. regards pallavi

                        T Offline
                        T Offline
                        ThatsAlok
                        wrote on last edited by
                        #11

                        mpallavi wrote: .. My phone book is ready.. When will you show us demo

                        "Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow

                        cheers, Alok Gupta

                        M 1 Reply Last reply
                        0
                        • T ThatsAlok

                          mpallavi wrote: .. My phone book is ready.. When will you show us demo

                          "Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow

                          cheers, Alok Gupta

                          M Offline
                          M Offline
                          mpallavi
                          wrote on last edited by
                          #12

                          Hi Allok.. ThatsAlok wrote: When will you show us demo Anytime.. But.. its working partially..:( .. bad news in the morning itself.. i can save the numbers but cannot delete them.. next time when i run the application the numbers are present in the list even if i cleared in the previous run.. pallavi

                          T 1 Reply Last reply
                          0
                          • M mpallavi

                            Hi Allok.. ThatsAlok wrote: When will you show us demo Anytime.. But.. its working partially..:( .. bad news in the morning itself.. i can save the numbers but cannot delete them.. next time when i run the application the numbers are present in the list even if i cleared in the previous run.. pallavi

                            T Offline
                            T Offline
                            ThatsAlok
                            wrote on last edited by
                            #13

                            mpallavi wrote: Hi Allok.. My Name has Only one L i.e. Alok :) mpallavi wrote: next time when i run the application the numbers are present in the list even if i cleared in the previous run.. How many number you store in list and where are you storing the number?

                            "Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow

                            cheers, Alok Gupta

                            M 1 Reply Last reply
                            0
                            • T ThatsAlok

                              mpallavi wrote: Hi Allok.. My Name has Only one L i.e. Alok :) mpallavi wrote: next time when i run the application the numbers are present in the list even if i cleared in the previous run.. How many number you store in list and where are you storing the number?

                              "Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow

                              cheers, Alok Gupta

                              M Offline
                              M Offline
                              mpallavi
                              wrote on last edited by
                              #14

                              Hi Alok.. (Sorry for spelling ur name incorrectly!).. I borrowed a class that maintained the history in a registry (from codeguru articles).. here is the link.. http://www.codeguru.com/Cpp/controls/combobox/article.php/c4955/[^] ........ i don't know where exactly the values are getting saved.. but they persist even if i clear the combo box.. ragards pallavi

                              T 1 Reply Last reply
                              0
                              • M mpallavi

                                Hi Alok.. (Sorry for spelling ur name incorrectly!).. I borrowed a class that maintained the history in a registry (from codeguru articles).. here is the link.. http://www.codeguru.com/Cpp/controls/combobox/article.php/c4955/[^] ........ i don't know where exactly the values are getting saved.. but they persist even if i clear the combo box.. ragards pallavi

                                T Offline
                                T Offline
                                ThatsAlok
                                wrote on last edited by
                                #15

                                Why Don't you create your own by using RegKey :)

                                "Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow

                                cheers, Alok Gupta

                                M 1 Reply Last reply
                                0
                                • T ThatsAlok

                                  Why Don't you create your own by using RegKey :)

                                  "Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow

                                  cheers, Alok Gupta

                                  M Offline
                                  M Offline
                                  mpallavi
                                  wrote on last edited by
                                  #16

                                  Running out of time.........:( pal

                                  T 1 Reply Last reply
                                  0
                                  • M mpallavi

                                    Running out of time.........:( pal

                                    T Offline
                                    T Offline
                                    ThatsAlok
                                    wrote on last edited by
                                    #17

                                    mpallavi wrote: Running out of time......... That much, how many member team do u have :~

                                    "Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow

                                    cheers, Alok Gupta

                                    M 1 Reply Last reply
                                    0
                                    • T ThatsAlok

                                      mpallavi wrote: Running out of time......... That much, how many member team do u have :~

                                      "Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow

                                      cheers, Alok Gupta

                                      M Offline
                                      M Offline
                                      mpallavi
                                      wrote on last edited by
                                      #18

                                      ThatsAlok wrote: how many member team do u have He He .. its an individual project dear.. i am in my final semester MCA.. we had to undertake a 4 months full time project.. .. Pal

                                      T 1 Reply Last reply
                                      0
                                      • M mpallavi

                                        ThatsAlok wrote: how many member team do u have He He .. its an individual project dear.. i am in my final semester MCA.. we had to undertake a 4 months full time project.. .. Pal

                                        T Offline
                                        T Offline
                                        ThatsAlok
                                        wrote on last edited by
                                        #19

                                        mpallavi wrote: He He .. its an individual project dear.. i am in my final semester MCA.. we had to undertake a 4 months full time project.. Yeah, I Remember I too done project in my six month training last year :) but it part of my BIT course(4 yr). So in whihc company are you talking Training:)

                                        "Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow

                                        cheers, Alok Gupta

                                        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