Framework mismatch resolution

Closed
0
0

Happy new year everybody,

just want to share this with you. After upgrading to net8.0 my project would not compile any more:

Error CS1705 System.Runtime, Version=8.0.0.0  which has a higher version than referenced assembly ‘System.Runtime’ with identity ‘System.Runtime, Version=4.1.2.0 (net48)

This error stems from a referenced DLL compiled against net8.0.

So I added a configurtaion “Design” to my solution with target frameworks net48 and net8.0. All other configurations target net8.0 only (in *.csproj):

<PropertyGroup>
<TargetFrameworks Condition=”‘$(Configuration)’ == ‘Design'”>net48;net8.0</TargetFrameworks>
<TargetFrameworks Condition=”‘$(Configuration)’ != ‘Design'”>net8.0</TargetFrameworks>

</PropertyGroup>

Just start visual studio in “Design” to use the visual designer and compile or publish, say, in “Release”. Not perfect but it works. Maybe there is a better solution?

Hopefully net48 for Wisej is history very soon.

Happy coding and don’t be afraid to get your hands dirty.

Cheers, Gerhard

  • You must to post comments
0
0

.NET 48 is widely used by a large number of projects in production. We don’t see any reason not to keep supporting it for the foreseeable future. There are many systems that cannot work on NET core due to a lack of a proper implementation.

Wisej.NET 4 will include a designer for NET Core.

This issue doesn’t appear to identify any bug. Multitargeting and editing csproj js is normal.

 

  • You must to post comments
Showing 1 result