3

We have to use DNX core 5 and OpenXml, for XLS export, in our app.

It seems like the OpenXml dependency is not supported, according to the error message I got:

Error  NU1002  The dependency DocumentFormat.OpenXml 2.5.0 in project does not support framework DNXCore,Version=v5.0. project.json    

Here is the part of the project.json associated with the problem:

"frameworks": {
"dnx451": {
  "dependencies": { },
  "frameworkAssemblies": {
    "WindowsBase": "4.0.0.0"
  }
},
"dnxcore50": {
  "dependencies": {
  }
}},

Adding manually the same frameworkAssemblies element to the "dnxcore50" node does not seem to fix the problem.

Removing the "dnxcore50" node makes the app to compile, but this compromises the benefits of dnx Core 5.0 advantages.

This similar question did not properly answer my question : Open XML in dnx5.0 / aspnext

Does anyone have a solution ?

Community
  • 1
  • 1
Christopher J.
  • 1,154
  • 1
  • 12
  • 21
  • 2
    There needs to be an updated Open XML library from Microsoft or a third party to address that. – Lex Li Nov 20 '15 at 11:03
  • Looks like this is opensource library, so you may try to rebuild it with dnx platform/ – FLCL Nov 23 '15 at 15:34

2 Answers2

1

Unfortunately there is currently no nuget package for the Open Xml SDK. However, some people are already working on creating such a package: https://github.com/OfficeDev/Open-XML-SDK/issues/65

Simon Mattes
  • 4,866
  • 2
  • 33
  • 53
0

Update 24th May. The community worked for .NET Standard support . It should work for .NET Core, if not it will be very soon.

Follow the evolution here: https://dotnet.myget.org/gallery/open-xml-sdk

Christopher J.
  • 1,154
  • 1
  • 12
  • 21