Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

819
Vistas
Published version WPF .NET Core

I am looking to use the format as below, but in a .net core WPF C# application. Here is how I used to use it.

public static string GetVersion()
{
   if (System.Deployment.Application.ApplicationDeployment.IsNetworkDeployed)
   {
      Version myVersion = ApplicationDeployment.CurrentDeployment.CurrentVersion;
      return $"Version {myVersion}";
   }
   return "Version not deployed";
}

Is there a matching process in .net core please? Thanks

over 4 years ago · Santiago Trujillo
2 Respuestas
Responde la pregunta

0

There is a closed issue around this issue and ClickOnce deployment.

ApplicationDeployment class is not available - that class is implemented in System.Deployment assembly that is not part of .NET Core 3.1 or .NET 5.

We will have a way to expose some of the properties that the class enables, i.e. URL parameters and update status. But, that work could not be completed for .NET 5 release. We will enable it in one of .NET 6 previews. Here are the tracking issues: #27 and #53

Use of ApplicationDeployment class in your deployed ClickOnce application is not possible, but main ClickOnce experience is available. It includes: creating ClickOnce deployment (manifests), publishing the application, creating and publishing updates. Your application will get automatic update check (and update, if user accepts it) - this part is handled by ClickOnce runtime and the new Launcher tool that becomes the entry point of ClickOnce deployment for .NET Core 3.1 and .NET 5 applications.

Consequently, as for now there does not seem to be a way to do this in .NET Core directly.

over 4 years ago · Santiago Trujillo Denunciar

0

You should be able to get the assembly version using System.Reflection.Assembly.GetExecutingAssembly().GetName().Version, as shown in Reading Assembly version information of WPF application

For more click-once capabilities not ported to .net core3.1/5/6, look here https://github.com/derskythe/WpfSettings

over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda