windowsforms-devexpress-dot-xtrabars-dot-ribbon-dot-ribboncontrol-517ee3d9.md
Gets or sets whether the RibbonControl automatically saves its layout when the parent form is closed.
Namespace : DevExpress.XtraBars.Ribbon
Assembly : DevExpress.XtraBars.v25.2.dll
NuGet Package : DevExpress.Win.Navigation
[DefaultValue(false)]
[DXCategory("Behavior")]
[XtraSerializableProperty]
public bool AutoSaveLayoutToXml { get; set; }
<DXCategory("Behavior")>
<DefaultValue(False)>
<XtraSerializableProperty>
Public Property AutoSaveLayoutToXml As Boolean
| Type | Default | Description |
|---|---|---|
| Boolean | false |
true to save RibbonControl layout when the parent form is closed; otherwise, false.
|
A user can customize a RibbonControl at runtime if the RibbonControl.AllowCustomization property is set to true. The Ribbon Customization Window allows users to save a customized ribbon layout to an XML file. You can also set the AutoSaveLayoutToXml property to true to enable the auto-save layout feature. In this case, ribbon layout is automatically saved to an XML file (RibbonControl.AutoSaveLayoutToXmlPath) when the parent form is closed. If the auto-save path is not defined, the RibbonControl.InvalidSaveRestoreLayoutException event occurs.
Note
When the AutoSaveLayoutToXml option is enabled, RibbonControl may restore its layout incorrectly if you modify the layout at design-time. Refer to the following help topics for more information: Post-restore Customization and Upgrading Layout.
See Also