Back to Devexpress

PlainTextBox.Text Property

officefileapi-devexpress-dot-xtrarichedit-dot-api-dot-layout-dot-plaintextbox.md

latest3.2 KB
Original Source

PlainTextBox.Text Property

Returns the text displayed in the current PlainTextBox element.

Namespace : DevExpress.XtraRichEdit.API.Layout

Assembly : DevExpress.RichEdit.v25.2.Core.dll

NuGet Package : DevExpress.RichEdit.Core

Declaration

csharp
public string Text { get; }
vb
Public ReadOnly Property Text As String

Property Value

TypeDescription
String

A string that is the text displayed in the layout element.

|

The following code snippets (auto-collected from DevExpress Examples) contain references to the Text property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

winforms-richedit-layout-api-practical-usage/CS/WindowsFormsApplication1/DocumentLayoutHelper/DocumentElementLayoutHelper.cs#L15

csharp
string returnedInformation = "!A REGULAR TEXT BLOCK IS SELECTED!\r\n";
returnedInformation += String.Format("Content: {0}\r\n", currentTextBlock.Text);

winforms-richedit-layout-api-practical-usage/VB/WindowsFormsApplication1/DocumentLayoutHelper/DocumentElementLayoutHelper.vb#L18

vb
Dim returnedInformation As String = "!A REGULAR TEXT BLOCK IS SELECTED!" & Constants.vbCrLf
returnedInformation &= String.Format("Content: {0}" & Constants.vbCrLf, currentTextBlock.Text)

richedit-winforms-layout-element-under-cursor/VB/ToolTip/Form1.vb#L40

vb
If element.Parent.Type = LayoutType.PlainTextBox Then
    text += String.Format(Microsoft.VisualBasic.Constants.vbCrLf & "PlainTextBox : ""{0}""", TryCast(element.Parent, PlainTextBox).Text)
    text += GetBounds(element.Parent)

See Also

PlainTextBox Class

PlainTextBox Members

DevExpress.XtraRichEdit.API.Layout Namespace