dashboard-405258-get-started-build-wpf-dashboard-applications-create-wpf-dashboard-with-cli-project-template.md
You can use the .NET command-line interface (CLI) to create an application with the WPF Dashboard Viewer control from the console. Note that the project template targets .NET 8.0+ and supports C# only.
Note
We implemented a new dotnet CLI-powered Project Wizard you can use across multiple IDEs: Cross-IDE Project Template Kit.
Execute the following command to install DevExpress WPF project templates from nuget.org:
dotnet new install DevExpress.WPF.ProjectTemplates
If the NuGet.org package source is disabled, you will get the following error: NU1101: Unable to find package DevExpress.WPF.ProjectTemplates. To see the list of sources and their status information, run the command dotnet nuget list source. To enable a source, run the command dotnet nuget enable source <source name>.
If you are new to NuGet, visit the following page for more information about package management prerequisites: An Introduction to NuGet.
Note
DevExpress CLI project templates are also available in the DevExpress NuGet Gallery (nuget.devexpress.com).
To create a WPF Dashboard Viewer application, execute the following command:
dotnet new dx.wpf.dashboard -n WpfDashboardViewer
The command creates a WPF application with Dashboard Viewer application called WpfDashboardViewer in the current directory.
You can use the following parameters to see available command options: -? | -h | --help. For example, execute the following command:
dotnet new dx.wpf.dashboard --help
Refer to the following documents for information on template options:
dotnet new command - OptionsStandard options for .NET CLI templates.Template OptionsOptions specific to the DevExpress WPF templates.
You need to configure your personal DevExpress NuGet Feed to load the required DevExpress component packages and build the resulting project. Follow the instructions below:
The following list contains options you can specify when creating DevExpress WPF BI Dashboard project templates:
-prerelease, --use-prerelease-dx-versionA flag that indicates whether to use a pre-release DevExpress package version in the project.--framework <TFM>Specifies the target framework. It expects a target framework moniker (TFM). Example: net8.0.--dx-version <version>Specifies DevExpress package version to be used in the project. Examples: 25.2.3, 25.2.*, 25.2.*-*``--dx-nuget-feed <feed>Specifies the NuGet Feed URL. Refer to nuget.devexpress.com to obtain your personal feed URL (available for registered users).-preload, --preload-resources
Preload theme resources on application launch to speed up the display time for all subsequent windows. For more information, refer to Preload Theme Resources.
Default: true
-lwthemes, --lightweight-themes
Use DevExpress lightweight themes instead of regular themes. For more information, refer to Lightweight Themes.
Default: true