SetWindowText(..)只能一次改变所有的文字。

解决方案 »

  1.   

    移动光标到最后:SetSel()
    插入文字:StreamIn()
      

  2.   

    CString strOld ;
    strOld = GetWindowText();
    strNew = strOld + "\r\n" + strNew;
    SetWindowText(strNew);
      

  3.   

    3jaja(3++输入法) :
    插入文字:StreamIn()怎么用啊,
    msdn说要自己指定一个函数,还是要通过这个函数来自己读文件
      

  4.   

    这样吧,更简单的方法;
    将内容复制到剪贴板,
    移动光标到最后:SetSel()
    copy()即可.
      

  5.   

    可以这样做:
    void writeText(const char* temp,CRichEditCtrl *hout)
    {
        hout->ReplaceSel(temp);
        hout->ReplaceSel("\r\n");
    }
    这样就ok了。
      

  6.   

    www.codeguru.com/richedit/rtf_string_treamin.shtml
      

  7.   

    http://www.codeguru.com/richedit/dalrichedit.shtml