Back to Devexpress

XtraForm.Text Property

windowsforms-devexpress-dot-xtraeditors-dot-xtraform-40c67da5.md

latest6.0 KB
Original Source

XtraForm.Text Property

Gets or sets the form’s caption.

Namespace : DevExpress.XtraEditors

Assembly : DevExpress.Utils.v25.2.dll

NuGet Packages : DevExpress.Utils, DevExpress.Wpf.Core

Declaration

csharp
[DXCategory("Behavior")]
public override string Text { get; set; }
vb
<DXCategory("Behavior")>
Public Overrides Property Text As String

Property Value

TypeDescription
String

A string that specifies the form’s caption.

|

Remarks

You can format a form’s caption using HTML tags via the XtraForm.HtmlText property.

Setting the Text property clears the XtraForm.HtmlText property.

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-obtain-the-document-position-under-the-mouse-cursor/CS/RichEdit_GetPositionFromPoint/Form1.cs#L26

csharp
if (pos != null)
    this.Text = System.String.Format("Mouse is over position {0}",pos);
else this.Text = "";

winforms-mvvm-expenses-app/CS/MVVMExpenses/Views/MainView.cs#L43

csharp
if(string.IsNullOrEmpty(userName))
    this.Text = "Expenses Application";
else

winforms-richedit-document-api/CS/RichEditAPISample/Form1.cs#L557

csharp
if (pos != null)
    this.Text = System.String.Format("Mouse is over position {0}", pos);
else this.Text = "";

excel-export-library-generate-a-list-of-employees/CS/XLExportExample/Form1.cs#L90

csharp
DialogResult dResult = MessageBox.Show(String.Format("Do you want to open the resulting file?", fileName),
    this.Text, MessageBoxButtons.YesNo, MessageBoxIcon.Question);
if (dResult == DialogResult.Yes)

winforms-tabbed-mdi-manager-display-custom-header-button/CS/WindowsFormsApplication32/Form1.cs#L20

csharp
xtraForm.MdiParent = this;
xtraForm.Text = "Form 1";
xtraForm.Show();

winforms-mvvm-expenses-app/VB/MVVMExpenses/Views/MainView.vb#L45

vb
If String.IsNullOrEmpty(userName) Then
    Me.Text = "Expenses Application"
Else

winforms-tabbed-mdi-manager-display-custom-header-button/VB/WindowsFormsApplication32/Form1.vb#L19

vb
xtraForm.MdiParent = Me
xtraForm.Text = "Form 1"
xtraForm.Show()

winforms-dashboard-obtain-dashboard-item-client-data/VB/Dashboard_ClientDataCards_Win/Form1.vb#L57

vb
Dim form As New XtraForm()
form.Text = title
form.Bounds = New Rectangle(100, 100, 700, 350)

how-to-implement-a-custom-inplace-editor-for-appointments-e4826/VB/SchedulerInplaceEditorExample/MyInplaceEditor.vb#L22

vb
InitializeComponent()
Me.Text = String.Empty
Me.ControlBox = False

winforms-dashboard-add-custom-interactivity-to-dashboard/VB/Dashboard_CustomVisualInteractivity/Form1.vb#L50

vb
Dim form As New XtraForm()
form.Text = e.GetAxisPoint(DashboardDataAxisNames.ChartArgumentAxis).DimensionValue.Value.ToString() & " - " & e.GetAxisPoint(DashboardDataAxisNames.ChartSeriesAxis).DimensionValue.Value.ToString()
Dim grid As New DataGrid()

See Also

HtmlText

HTML-inspired Text Formatting

XtraForm Class

XtraForm Members

DevExpress.XtraEditors Namespace