Back to Devexpress

ActionBase.Id Property

expressappframework-devexpress-dot-expressapp-dot-actions-dot-actionbase.md

latest3.2 KB
Original Source

ActionBase.Id Property

Specifies an Action‘s identifier.

Namespace : DevExpress.ExpressApp.Actions

Assembly : DevExpress.ExpressApp.v25.2.dll

NuGet Package : DevExpress.ExpressApp

Declaration

csharp
public string Id { get; set; }
vb
Public Property Id As String

Property Value

TypeDescription
String

A string property that represents the current Action’s identifier.

|

Remarks

By default, this property is set to a GUID. You can set another value in the Controller’s contructor or Designer. This value will be saved to the Application Model‘s IModelAction node.

Note

An Action’s identifier must be unique. For instance, you can set values like namespaces: “MyApp.FinancialOperations.AddTurnoverAction”.

The following code snippets (auto-collected from DevExpress Examples) contain references to the Id 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.

xaf-win-custom-action-with-custom-action-control/CS/EFCore/CustomActionEF/CustomActionEF.Win/Controllers/CustomActionControlController.cs#L17

csharp
BarLinkActionControlContainer container = (BarLinkActionControlContainer)e.Container;
IActionControl actionControl = CreateActionControl(e.Action.Id, container.BarContainerItem);
container.AddActionControl(actionControl);

XAF_How-to-get-role-code-from-the-UI/CS/XPO/GenerateRole/GenerateRole.Module/Controllers/RoleGeneratorController.cs#L27

csharp
roleGeneratorAction.ConfirmationMessage = null;
roleGeneratorAction.Id = "RoleGeneratorAction";
roleGeneratorAction.ImageName = "Action_Export";

See Also

ActionBase Class

ActionBase Members

DevExpress.ExpressApp.Actions Namespace