XtraForm.MdiChildCaptionFormatString Property

Gets or sets the composite format string used to format the merged MDI parent and child captions.

Namespace: DevExpress.XtraEditors

Assembly: DevExpress.Utils.v20.1.dll

Declaration

[DefaultValue("{1} - {0}")]
[DXCategory("Behavior")]
public virtual string MdiChildCaptionFormatString { get; set; }
<DefaultValue("{1} - {0}")>
<DXCategory("Behavior")>
Public Overridable Property MdiChildCaptionFormatString As String

Property Value

Type Default Description
String

"{1} - {0}"

A string value that represents the composite format string used to format the merged MDI parent and child captions.

Remarks

If the XtraForm.ShowMdiChildCaptionInParentTitle property is set to true, the MDI parent and child captions are merged, and the resulting string is shown in the title bar. See the figure below.

XtraForm_ShowMdiChildCaptionInParentTitle_True

By default, the resulting string is composed of the child caption preceding the parent caption separated by a hyphen. The MdiChildCaptionFormatString property allows you to provide a custom format sting used to compose the captions. The {0} placeholder corresponds to the MDI parent caption, {1} corresponds to the child caption. The code snippet below shows a sample format string.


MdiChildCaptionFormatString = "{0} [{1}]";

The result of the provided formatting is shown below.

XtraForm_MdiChildCaptionFormatString

To learn more about composite format strings, see the Composite Formatting topic on MSDN.

See Also