title | description | ms.date | ms.topic | helpviewer_keywords | author | ms.author | manager | ms.subservice | monikerRange | |
---|---|---|---|---|---|---|---|---|---|---|
ClickOnce for .NET 5 and later on Windows |
Discover the differences between ClickOnce for .NET Core 3.1 and .NET 5 and later versions, versus ClickOnce for .NET Framework. |
09/06/2023 |
how-to |
|
mikejo5000 |
mikejo |
mijacobs |
deployment |
>= vs-2019 |
This article describes the differences between ClickOnce for .NET Core 3.1, .NET 5, and later, versus ClickOnce for .NET Framework.
Starting in Visual Studio 2019, ClickOnce for .NET Core 3.1 and .NET 5 or later uses the Publish tool instead of the Publish Wizard and properties pages. The Publish tool creates a .pubxml file, called a publish profile. Most of the properties previously available in the wizard are available to configure in the Publish tool. For detailed instructions, see Deploy a .NET Windows application using ClickOnce.
For building from the command line using MSBUILD, you need to specify the .pubxml file. For more information, see Build .NET ClickOnce applications from the command line.
In .NET Core 3.1, .NET 5, and .NET 6, you don't have programmatic access to the xref:System.Deployment.Application.ApplicationDeployment class or to other APIs in the xref:System.Deployment.Application namespace.
::: moniker range=">=vs-2022"
Starting in .NET 7, you can access properties in the ApplicationDeployment
class using environment variables. For more information, see Access ClickOnce deployment properties in .NET.
::: moniker-end
In .NET Core 3.1 and .NET 5 and later, use dotnet-mage.exe instead of Mage.exe to create the ClickOnce deployment.
You can install dotnet-mage.exe using the NuGet package.
To access activation data using dotnet-mage.exe, see Access ClickOnce activation data for .NET.
Security settings
- Enable ClickOnce Security Settings (Code access security)
- TargetZone
Update settings