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. to make a phone

to make a phone

Scheduled Pinned Locked Moved C / C++ / MFC
6 Posts 5 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.
  • Y Offline
    Y Offline
    yogendra kaushik
    wrote on last edited by
    #1

    i want to know,that as i insert a edit box on dialog box and 10 buttons with number on them from 0 to 9. now i want that when i press these 0-9 buttons then that will be appear on edit box . I use a progress control on dialog box and a dial button so that after entering numbers press dial and progress button start moving I want as in phone system when we press buttons they appear on screen and when dial button is pressed phone dials. Please mail me

    A D _ T 4 Replies Last reply
    0
    • Y yogendra kaushik

      i want to know,that as i insert a edit box on dialog box and 10 buttons with number on them from 0 to 9. now i want that when i press these 0-9 buttons then that will be appear on edit box . I use a progress control on dialog box and a dial button so that after entering numbers press dial and progress button start moving I want as in phone system when we press buttons they appear on screen and when dial button is pressed phone dials. Please mail me

      A Offline
      A Offline
      Amit Agarrwal
      wrote on last edited by
      #2

      m_sPhoneNumber += "1"; setDlgItemText(IDC_EDIT_PHONE_NUMBER,m_sPhoneNumber); put that code on button click. sPhoneNumber is a String. this code might help u.

      Y 1 Reply Last reply
      0
      • A Amit Agarrwal

        m_sPhoneNumber += "1"; setDlgItemText(IDC_EDIT_PHONE_NUMBER,m_sPhoneNumber); put that code on button click. sPhoneNumber is a String. this code might help u.

        Y Offline
        Y Offline
        yogendra kaushik
        wrote on last edited by
        #3

        thank you but this code does not sotore number on edit box as it replace preivious number i wantr as we use in mobile phone thank s Please mail me

        1 Reply Last reply
        0
        • Y yogendra kaushik

          i want to know,that as i insert a edit box on dialog box and 10 buttons with number on them from 0 to 9. now i want that when i press these 0-9 buttons then that will be appear on edit box . I use a progress control on dialog box and a dial button so that after entering numbers press dial and progress button start moving I want as in phone system when we press buttons they appear on screen and when dial button is pressed phone dials. Please mail me

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

          About how many times are you going to ask this question? It's been answered several times.


          "The largest fire starts but with the smallest spark." - David Crow

          "Judge not by the eye but by the heart." - Native American Proverb

          1 Reply Last reply
          0
          • Y yogendra kaushik

            i want to know,that as i insert a edit box on dialog box and 10 buttons with number on them from 0 to 9. now i want that when i press these 0-9 buttons then that will be appear on edit box . I use a progress control on dialog box and a dial button so that after entering numbers press dial and progress button start moving I want as in phone system when we press buttons they appear on screen and when dial button is pressed phone dials. Please mail me

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

            Here's the code for one more time. You can call this function whenever the key is pressed and pass an integer to the function underneath based on what button is clicked on the dialog by the user. m_editCtrl is the control variable for the edit box

            In the header file declare the function as
            void SetNewText(int p); // In the public section
            void CYourClass::SetNewText(int p)
            {
            CString s;
            m_editCtrl.GetWindowText(s);
            CString t;
            t.Format ("%d",p);
            s+=t;
            m_editCtrl.SetWindowText (s);

            }

            Now to use the function simply do SetNewText(1); //if the user has clicked 1 and so on Somethings seem HARD to do, until we know how to do them. ;-)_AnShUmAn_ -- modified at 9:27 Friday 7th July, 2006

            1 Reply Last reply
            0
            • Y yogendra kaushik

              i want to know,that as i insert a edit box on dialog box and 10 buttons with number on them from 0 to 9. now i want that when i press these 0-9 buttons then that will be appear on edit box . I use a progress control on dialog box and a dial button so that after entering numbers press dial and progress button start moving I want as in phone system when we press buttons they appear on screen and when dial button is pressed phone dials. Please mail me

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

              yogendra kaushik wrote:

              I want as in phone system when we press buttons they appear on screen and when dial button is pressed phone dials.

              try this :- http://www.codersource.net/mfc\_array\_controls.aspx

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

              cheers, Alok Gupta VC Forum Q&A :- I/ IV Support CRY- Child Relief and You

              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