CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 5 of 5

Thread: CEdit

  1. #1
    Join Date
    May 1999
    Posts
    5

    CEdit

    Can i create two var. in an CEDitBox, i.e an CString and an CEdit ?
    if i use the CSting how can i give the handle to the CEdit?.
    Please it's urgent??


  2. #2
    Join Date
    May 1999
    Location
    Reading, England
    Posts
    28

    Re: CEdit

    I assume you are talking about DDX member variables associated with your CEdit.

    If thats the case, you can define BOTH a CString and a CEdit member using ClassWizard.



  3. #3
    Join Date
    May 1999
    Posts
    5

    Re: CEdit

    i tried this but i have access to the CString an not to the CEdit
    I try to write something with the CString var. and to clear the CEditBox by the CEdit var. there are no effect and debugger wrote {CEdit hWnd = 0x00010478}.



  4. #4
    Join Date
    May 1999
    Location
    Reading, England
    Posts
    28

    Re: CEdit

    I don't understand what you are trying to do.

    > i tried this but i have access to the CString an not to the CEdit

    If you added a CEdit member variable using classwizard, you have access to it throughout the scope of your dialog class in the same way as the CString member.

    > I try to write something with the CString var.

    You mean assign a value to the CString and have it appear in the edit box?

    csText = "blah";
    UpdateData(FALSE);

    - or -

    csText = "blah";
    m_EditBox.SetWindowText(csText);

    > and to clear the CEditBox by the CEdit var

    ???
    m_EditBox.SetWindowText("");

    Why not post the code fragment causing the problem...



  5. #5
    Join Date
    May 1999
    Posts
    5

    Re: CEdit

    the problem is solved i need to write before using the CEdit(m_edit) var
    *******************
    UpdateData(TRUE);
    m_edit.Clear;
    ********************
    and not UpdateData(FALSE); after




Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured