Help Center

CRichEditCtx.Textmethod

Gets/sets the text from a rich edit control.

Windowsmethoddocumented

Syntax

PRIVATE PROPERTY CRichEditCtx.Text () AS DWSTRING

Parameters

NameDescription
wszTextA WSTRING with the new text.

Return value

(GET) The retrieved text.

(SET) The return value is TRUE if the text is set. Call GetErrorInfo to get information about the result.

Description

Gets/sets the text from a rich edit control.

Remarks

The Windows API function GetWindowTextW can also be used to retrieve the text of a rich edit control, but it cannot retrieve the text of a control in another application.

Examples

(GET) PROPERTY Text () AS DWSTRING (SET) PROPERTY Text (BYREF wszText AS WSTRING)

DIM dws AS DWSTRING = pRichEdit.Text

DIM dws AS DWSTRING = "New text" pRichEdit.Text = dws

Reference

  • Defined in AfxNova/CRichEditCtx.inc:1748
  • Documented in Windows/WIndows Controls/RichEdit/CRichEditCtx Class.md
  • Topic: CRichEditCtx Class