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. Ask a problem,About CEdit control

Ask a problem,About CEdit control

Scheduled Pinned Locked Moved C / C++ / MFC
helpc++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.
  • R Offline
    R Offline
    rxgmoral
    wrote on last edited by
    #1

    Ask a problem,About CEdit control i write code..... <<<<<<<<>>>>>>> ****************CmEdit.h********** class AFX_NOVTABLE CmEdit : public CEdit { public: __declspec(dllexport) CString CmGetDlgItem(int nID); }; ***************CmEdit.Cpp********** CString CmEdit::CmGetDlgItem(int nID) { CString Str; GetDlgItem(nID)->GetWindowTextW(Str); return Str; } <<<<<<<<<<<>>>>>>>>>>>> #pragma comment(lib,"Dll.lib") #include "CmEdit.h" void SocialSecurityData::OnBnClickedOk() { CmEdit d; CString r=d.CmGetDlgItem(IDC_EDIT1); MessageBox(r); } Start Debugging..... Error............... Why???? thank:)

    M V H 3 Replies Last reply
    0
    • R rxgmoral

      Ask a problem,About CEdit control i write code..... <<<<<<<<>>>>>>> ****************CmEdit.h********** class AFX_NOVTABLE CmEdit : public CEdit { public: __declspec(dllexport) CString CmGetDlgItem(int nID); }; ***************CmEdit.Cpp********** CString CmEdit::CmGetDlgItem(int nID) { CString Str; GetDlgItem(nID)->GetWindowTextW(Str); return Str; } <<<<<<<<<<<>>>>>>>>>>>> #pragma comment(lib,"Dll.lib") #include "CmEdit.h" void SocialSecurityData::OnBnClickedOk() { CmEdit d; CString r=d.CmGetDlgItem(IDC_EDIT1); MessageBox(r); } Start Debugging..... Error............... Why???? thank:)

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

      What error message do you get, also why are you using GetWindowTextW directly


      To all the virgins in the world thanks for Nothing.

      1 Reply Last reply
      0
      • R rxgmoral

        Ask a problem,About CEdit control i write code..... <<<<<<<<>>>>>>> ****************CmEdit.h********** class AFX_NOVTABLE CmEdit : public CEdit { public: __declspec(dllexport) CString CmGetDlgItem(int nID); }; ***************CmEdit.Cpp********** CString CmEdit::CmGetDlgItem(int nID) { CString Str; GetDlgItem(nID)->GetWindowTextW(Str); return Str; } <<<<<<<<<<<>>>>>>>>>>>> #pragma comment(lib,"Dll.lib") #include "CmEdit.h" void SocialSecurityData::OnBnClickedOk() { CmEdit d; CString r=d.CmGetDlgItem(IDC_EDIT1); MessageBox(r); } Start Debugging..... Error............... Why???? thank:)

        V Offline
        V Offline
        Vipin Aravind
        wrote on last edited by
        #3

        You seem to be doing something simple the tough way by handcoding. Can you tell me what you are wanting to accomplish and I can tell you do that effectively using vc++ IDE. Vipin - Microsoft MVP http://www.explorewindows.com

        M 1 Reply Last reply
        0
        • V Vipin Aravind

          You seem to be doing something simple the tough way by handcoding. Can you tell me what you are wanting to accomplish and I can tell you do that effectively using vc++ IDE. Vipin - Microsoft MVP http://www.explorewindows.com

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

          Vipin Aravind wrote:

          Vipin - Microsoft MVP

          Are you an MVP?


          Money is the root of all evil. For more information, send $10 to me.

          1 Reply Last reply
          0
          • R rxgmoral

            Ask a problem,About CEdit control i write code..... <<<<<<<<>>>>>>> ****************CmEdit.h********** class AFX_NOVTABLE CmEdit : public CEdit { public: __declspec(dllexport) CString CmGetDlgItem(int nID); }; ***************CmEdit.Cpp********** CString CmEdit::CmGetDlgItem(int nID) { CString Str; GetDlgItem(nID)->GetWindowTextW(Str); return Str; } <<<<<<<<<<<>>>>>>>>>>>> #pragma comment(lib,"Dll.lib") #include "CmEdit.h" void SocialSecurityData::OnBnClickedOk() { CmEdit d; CString r=d.CmGetDlgItem(IDC_EDIT1); MessageBox(r); } Start Debugging..... Error............... Why???? thank:)

            H Offline
            H Offline
            Hamid Taebi
            wrote on last edited by
            #5

            Wheres error?which line?We cant guess error in your code.

            _**


            **_

            WhiteSky


            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