expressappframework-devexpress-dot-persistent-dot-base-ff0f0f24.md
Specifies a tooltip for a business object property in XAF WinForms and ASP.NET Core Blazor applications.
Namespace : DevExpress.Persistent.Base
Assembly : DevExpress.ExpressApp.v25.2.dll
NuGet Package : DevExpress.ExpressApp
[AttributeUsage(AttributeTargets.Property | AttributeTargets.Field, Inherited = true, AllowMultiple = false)]
public class ToolTipAttribute :
ModelExportedValuesAttribute
<AttributeUsage(AttributeTargets.Property Or AttributeTargets.Field, Inherited:=True, AllowMultiple:=False)>
Public Class ToolTipAttribute
Inherits ModelExportedValuesAttribute
The ToolTipAttribute class allows you specify tooltips for business object properties. Additionally, you can use the Model Editor to configure tooltips for the following elements:
The model uses IModelToolTip.ToolTip, IModelToolTipOptions.ToolTipIconType, and IModelToolTipOptions.ToolTipTitle properties to specify tooltip settings.
Use ToolTipAttribute to assign a tooltip to a class property. Once set for a class member, the tooltip is assigned for all related UI elements:
Controls of Detail View items
Layout groups
Captions of layout items (not supported in Blazor applications)
List View column headers in GridListEditor and TreeListEditor (WinForms), DxGridListEditor and DxTreeListEditor (ASP.NET Core Blazor)
public class DemoTask : BaseObject {
// ...
[ToolTip("Provide a detailed task description.")]
public virtual string Notes { get; set; }
//...
}
Select BOModel | <ApplicationName>.Module.BusinessObjects | <ClassName> | OwnMembers | <PropertyName> and specify a value for the ToolTip property.
You can try this approach in the MainDemo application that is shipped with XAF and installed to the following default path: %PUBLIC%\Documents\DevExpress Demos 25.2\Components\XAF\MainDemo.NET.EFCore.
Select Views | <ApplicationName>.Module.BusinessObjects | <ClassName> | <ClassName>_DetailView | Layout | <…> | <GroupName> and specify a value for the ToolTip property.
Select NavigationItems | Items | <…> | <GroupOrItemName> and specify a value for the ToolTip property.
Object Attribute DevExpress.Persistent.Base.ModelExportedValuesAttribute ToolTipAttribute
See Also