Support for .NET 8

221 views
Skip to first unread message

Chintu

unread,
Oct 16, 2024, 4:05:23 AM10/16/24
to Excel-DNA
Hi, I am upgrading my Visual Studio solution from .NETc Framework 4.x to .NET 8. Is Excel DNA supported for the .NET 8 framework? I have installed the Excel DNA packages using NuGet from Visual Studio 2022. It seems to have installed versions 1.8.0 of all the excel DNA packages. I am, however, getting the below compilation error:

"The target platform should be specified as Windows in the project file. For example, <TargetFramework> net6.0-windows</TargetFramework>. {soln-name} C:/users/../.nuget/packages/exceldna.addin/1.8.0/build/ExcelDna.AddIn.targets

Can someone advise me what is going wrong?

Thanks in advance
Raj

Govert van Drimmelen

unread,
Oct 16, 2024, 4:37:51 AM10/16/24
to exce...@googlegroups.com

Hi Raj

 

Excel-DNA support the .NET 8 runtime, but only with the windows platform specified.

 

In your project file (.csproj or .vbproj) you’ll see a “TargetFramework” tag.

You need to set this as “net8.0-windows” instead of just “net8.0”.

So your TargetFramework tag to target .NET 8 would look like this

 

<TargetFramework>net8.0-windows</TargetFramework>

 

-Govert

--
You received this message because you are subscribed to the Google Groups "Excel-DNA" group.
To unsubscribe from this group and stop receiving emails from it, send an email to exceldna+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/exceldna/7aa339e1-e34b-4e11-acd1-7b9825fb6e93n%40googlegroups.com.

Message has been deleted

Chintu

unread,
Oct 17, 2024, 11:26:09 PM10/17/24
to Excel-DNA
Dear Govert, that was a very quick and accurate response. It works now, many thanks indeed for all your efforts.

Best wishes

Raj

Reply all
Reply to author
Forward
0 new messages