Abrir Fechadas

How we can get current abp app version and show it to in UI #883


User avatar
0
safi criada

Hi,

I want to show current abp version into my application so is there any way to get this. Please let me know.

Thanks,


4 resposta (s)
  • User Avatar
    0
    Moyaoxiang criada

    Hi safi, You can get the file version through GetFileVersion() and return it to the front-end page.

    var version = typeof(AbpModule).Assembly.GetFileVersion();
    

  • User Avatar
    0
    safi criada

    Hi

    We are adding this code into Host project and all pages are available into Blazor project so If I am adding this into host so I am getting version but If I am adding the same code into blazor then getting error like FileVersion is not supported error in console so please suggest me.

    Thanks,

  • User Avatar
    0
    alper criada
    Equipe de Apoio Director

    Maybe Blazor didn't implement this because it runs in your browser. Also Blazor is a client and you also have a host. So these projects have different versions. The best practise is storing Blazor client version in a const variable and get the host version via API call. Create a new application service like ApplicationInfoAppservice and return the version from this service...

  • User Avatar
    0
    ServiceBot criada
    Equipe de Apoio Automatic process manager

    This question has been automatically marked as stale because it has not had recent activity.

Made with ❤️ on ABP v8.2.0-preview Updated on março 25, 2024, 15:11