.NET Core API Framework Warning

Pratham Jain 221 Reputation points
2023-01-27T14:03:43.83+00:00

Hi All,

I am developing an application using .NET Core with angular client. I am exporting the data to excel and generating the file in C# .NET Core. I am using a nuget package for the same.

After installing the nuget package in the project I am getting the below warning message with warning icon shown with package name in Dependencies/Packages:

Package 'SmartExcel.Export 2018.6.18.1' was restored using '.NETFramework,Version=v4.6.1, .NETFramework,Version=v4.6.2, .NETFramework,Version=v4.7, .NETFramework,Version=v4.7.1, .NETFramework,Version=v4.7.2, .NETFramework,Version=v4.8, .NETFramework,Version=v4.8.1' instead of the project target framework 'net6.0'. This package may not be fully compatible with your project.

Please advise how can I resolve this issue ASAP.

Regards,

Pratham

ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,200 questions
{count} votes

Accepted answer
  1. AgaveJoe 26,141 Reputation points
    2023-01-27T14:21:21.36+00:00

    .NET 6 is not compatible with .NET Framework which is what the error message is telling you. Find an Excel library compatible with .NET 6.


1 additional answer

Sort by: Most helpful
  1. Srivastava, Prashant 1 Reputation point
    2023-01-31T09:27:25.62+00:00

    Since .NET 6 is actually .NET core (not .NET standard which is our traditional .NET framework). So, If you haven' t looked already you might wanna try Open XML, here is the reference link https://learn.microsoft.com/en-us/office/open-xml/how-to-parse-and-read-a-large-spreadsheet

    0 comments No comments