CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    Oct 2008
    Posts
    59

    Update MultiLine EditControl

    I am using a multi line edit control. Here the event will be hadle using a timer and it is updated in every seconds. In each time,the same variable will be updating. So I want to display the variable in edit control and it should update in each time by down to down( not overwriting)

    I have used
    Code:
    //.....bla...bla
    CString dispVar;
    m_list.SetWindowText[dispVar];
    .

    Here it is overwriting....
    How can It Update?? Plz help...

  2. #2
    VictorN's Avatar
    VictorN is offline Super Moderator Power Poster
    Join Date
    Jan 2003
    Location
    Hanover Germany
    Posts
    20,430

    Re: Update MultiLine EditControl

    Quote Originally Posted by arunkr6 View Post
    I have used
    Code:
    //.....bla...bla
    CString dispVar;
    m_list.SetWindowText[dispVar];
    .

    Here it is overwriting....
    How can It Update?? Plz help...
    1. you code is wrong. You must use (...), not [...]

    2. To append text to edit control you can either
    • read the old text in a CString, add the new text and then write the updated text back to control
    or
    • use CEdit::SetSel/CEdit::ReplaceSel functions.
    Victor Nijegorodov

  3. #3
    Join Date
    Oct 2002
    Location
    Timisoara, Romania
    Posts
    14,360

    Re: Update MultiLine EditControl

    Marius Bancila
    Home Page
    My CodeGuru articles

    I do not offer technical support via PM or e-mail. Please use vbBulletin codes.

  4. #4
    Join Date
    Oct 2008
    Posts
    59

    Resolved Re: Update MultiLine EditControl

    Thank u.... n it has worked...

Tags for this Thread

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