expressappframework-devexpress-dot-expressapp-dot-actions-dot-actionbase-b218d90e.md
Specifies the Action‘s paint style.
Namespace : DevExpress.ExpressApp.Actions
Assembly : DevExpress.ExpressApp.v25.2.dll
NuGet Package : DevExpress.ExpressApp
[DefaultValue(ActionItemPaintStyle.Default)]
public ActionItemPaintStyle PaintStyle { get; set; }
<DefaultValue(ActionItemPaintStyle.Default)>
Public Property PaintStyle As ActionItemPaintStyle
| Type | Default | Description |
|---|---|---|
| ActionItemPaintStyle | Default |
An ActionItemPaintStyle enumeration value that specifies the Action’s paint style.
|
Available values:
| Name | Description | Image |
|---|---|---|
| Default |
The default value is Image for WinForms applications and CaptionAndImage for ASP.NET Core Blazor applications.
| | | Caption |
An Action is displayed in the UI as a caption.
|
| | CaptionAndImage |
An Action is displayed in the UI as an image and a caption.
|
| | Image |
An Action is displayed in the UI as an image.
|
|
Use one of the following approaches to specify this property:
In code
In the Model Editor
Navigate to an ActionDesign | Actions | <Action> node and specify the IModelAction.PaintStyle property.
Note that the value specified in the Model Editor has a higher priority than the value specified in code. For more information, refer to the following topic: Application Model Basics.
The following code snippets (auto-collected from DevExpress Examples) contain references to the PaintStyle 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.
this.SelectViewVariantAction = new SingleChoiceAction(this, "SelectViewVariant", "Edit");
this.SelectViewVariantAction.PaintStyle = ActionItemPaintStyle.Caption;
this.SelectViewVariantAction.Execute += new SingleChoiceActionExecuteEventHandler(this.SelectViewVariantAction_Execute);
action.ImageName = imageName;
action.PaintStyle = ActionItemPaintStyle.Image;
action.ToolTip = toolTip;
xaf-how-to-import-data-in-xaf/CS/WinWebSolution.Module/ImportDataListViewController.cs#L37
importDataAction.Items.Add(item2);
importDataAction.PaintStyle = ActionItemPaintStyle.CaptionAndImage;
importDataAction.ItemType = SingleChoiceActionItemType.ItemIsOperation;
xaf-how-to-import-data-in-xaf/VB/WinWebSolution.Module/ImportDataListViewController.vb#L40
importDataAction_Renamed.Items.Add(item2)
importDataAction_Renamed.PaintStyle = ActionItemPaintStyle.CaptionAndImage
importDataAction_Renamed.ItemType = SingleChoiceActionItemType.ItemIsOperation
See Also