How to: Modify Action Properties in the Model Editor
- 2 minutes to read
This article describes how to modify an Action’s properties in the Model Editor. This tool allows you to browse and edit an Application Model in Visual Studio.
An Action is an abstract UI element. XAF generates the default UI based on the business classes you declare and the Application Model.
An Application Model is metadata that defines the navigation structure, data display formats, and available commands. It has a neutral format that you can adapt to any target platform.
Note
For the purposes of this article, you can use the MainDemo application installed as a part of the XAF package. The default location of the application is %PUBLIC%\Documents\DevExpress Demos 24.2\Components\XAF.
The instructions below explain how to change the tooltip and the confirmation message of the Clear Tasks button in the Main Toolbar.
In the Solution Explorer, expand the
MainDemo.Module
project and double-click the Model.DesignedDiffs.xafml file to open it in the Model Editor.Navigate to the ActionDesign | Actions | ClearTasksAction node. In the right pane, find the Misc section of the properties.
Set the
ConfirmationMessage
property toThis action will remove all tasks of the current Employee. Do you still want to proceed?
.- Set the
Tooltip
property toClear the task list of the current Employee
. Save the changes and run the application. Open the Employee Detail View. Hover the mouse pointer over the Clear Tasks button to see the tooltip:
- ASP.NET Core Blazor
- Windows Forms
Click the Clear Tasks button to see the confirmation message:
- ASP.NET Core Blazor
- Windows Forms
Note
You can also modify Action properties in code. Refer to the following topics for details:
- Add a Simple Action
- Describes how to implement a custom Action.
- Customize Controllers and Actions
- Explains how to customize a built-in Action or a third-party module Action.