visual-studionuget-package-restorexaf

Why is XAF Template creating projects with the wrong minor version number?


I like to create new XAF projects as a way of checking I am using the correct packages Yet I am unable to do this after upgrading to a new minor version.

For example, I have installed the latest version of XAF 24.1.5 Yet when I create a new solution with the wizard I see in Solution Explorer that the package version is 24.1.3

24.1.3 version

When I look at the project the minor version does not display

<Project Sdk="Microsoft.NET.Sdk">
  <PropertyGroup>
    <TargetFramework>net8.0</TargetFramework>
    <CheckEolTargetFramework>false</CheckEolTargetFramework>
    <Deterministic>false</Deterministic>
    <AssemblyVersion>1.0.*</AssemblyVersion>
    <FileVersion>1.0.0.0</FileVersion>
    <Configurations>Debug;Release;EasyTest</Configurations>
    <ImplicitUsings>enable</ImplicitUsings>
  </PropertyGroup>
  <ItemGroup>
    <None Remove="Model.DesignedDiffs.xafml" />
  </ItemGroup>
  <ItemGroup>
    <EmbeddedResource Include="Model.DesignedDiffs.xafml" />
  </ItemGroup>
  <ItemGroup>
    <PackageReference Include="DevExpress.ExpressApp" Version="24.1" />
    <PackageReference Include="DevExpress.ExpressApp.CodeAnalysis" Version="24.1" />
    <PackageReference Include="DevExpress.ExpressApp.ConditionalAppearance" Version="24.1" />
    <PackageReference Include="DevExpress.ExpressApp.EFCore" Version="24.1" />
    <PackageReference Include="DevExpress.ExpressApp.Objects" Version="24.1" />
    <PackageReference Include="DevExpress.ExpressApp.Validation" Version="24.1" />
    <PackageReference Include="DevExpress.Persistent.Base" Version="24.1" />
    <PackageReference Include="DevExpress.Persistent.BaseImpl.EFCore" Version="24.1" />
    <PackageReference Include="Microsoft.EntityFrameworkCore.SqlServer" Version="8.0.1" />
    <PackageReference Include="Microsoft.EntityFrameworkCore.InMemory" Version="8.0.1" />
    <PackageReference Include="Microsoft.EntityFrameworkCore.Proxies" Version="8.0.1" />
    <PackageReference Include="Microsoft.Data.SqlClient" Version="5.1.3" />
    <PackageReference Include="Azure.Identity" Version="1.11.4" />
    <PackageReference Include="System.IdentityModel.Tokens.Jwt" Version="6.34.0" />
  </ItemGroup>
</Project>

I see no versions 24.1.3 in the GAC

Why are the templates creating projects with incorrect version numbers?

I have tried setting the package source to

C:\Program Files\DevExpress 24.1\Components\System\Components\Packages

Then right clicking the solution and choosing Restore Nuget Packages

Also I have tried setting the package source to my Dev Express Feed

Neither solve the problem.

Update

I have no Visual Studio folder in %USERPROFILE%\Documents
I do have a Visual Studio 2022 folder. With an empty C# folder in it. Empty Folder

In VS2022 Tools->Options-> Projects and Solutions->Locatons
the User project template location is set to

 C:\Users\kirst\Documents\Visual Studio 2022\Templates\ProjectTemplates

Solution

  • In the end I uninstalled DevExpress 24.1.5 and reinstalled it. Repairing did not help.