xceedsoftware/DocX

DocX is not supported in .net core applications

tawfiqin opened this issue Β· 20 comments

DocX is not supported in asp.net core 1.0

I looked into it and it seems that the only dependencies which are not (yet) available in .NET Core are System.Drawing.Color and System.Drawing.FontFamily. These two might be replaced by platform independent implementations. If there is interest, I can further look into it.

FontFamily implementation was recently updated to platform independent code. So, Color is the last one.

Is someone currently working on the port?

As I remember, the only thing to update is Color type replacement. That isn't complicated. I will try to find some time soon and review the current implementation.

@mkorsukov I fear there is more to do than I thought on Aug, 18. Encryption and Compressions functionality may need some work as well as everything involving Windows Security Principals.

Any Update? :( i need it for my solution on linux

I tried to port it - see https://github.com/Jetro223/DocXNETCore

  1. Colors as hex string instead of System.Drawing.Color
  2. No images
  3. No file protection

The port can load docx files and the document can be modified in memory. But the call to Save() does not work (does not write the changes to disk) and at the moment I do not understand why. Any help appreciated :-)

The version at https://github.com/Jetro223/DocXNETCore is working now. (still no images for core, no file protection, colors as hex string).

I tried to port the unit tests without luck (for now...) - so I just tested a few methods (adding paragraphs etc.)

@Jetro223 Do you know if there are plans to get images working in Core?

@jasonhjohnson There are several projects trying to bring image processing to .NET Core e.g. https://github.com/JimBobSquarePants/ImageSharp but I did not try any of these yet

@dennishog added image support to the .NET Core port (using CoreCompat.System.Drawing)

System.Drawing is going to .NET Core so maybe us it in future - https://github.com/dotnet/corefx/issues/20325

What is the status of this? It looks like FontFamily is still dependant on System.Drawing - are there any work arounds so we can use DocX with netcore?

I think project can be easily ported on dot.net core.
With https://github.com/SixLabors/ImageSharp for Paragraph.cs
and using something like
int argb = Int32.Parse(color, NumberStyles.HexNumber); Color.FromArgb(argb);
from System.Drawing from dot.net core SDK instead of ColorTranslator

Sadly it looks like we're going to have to go with a license from another company due to lack of .net core support :( Really wish this was supported.

Hi,

"Xceed Words for .NET", the commercial version of DocX, will support .NET Core application on its next release v1.6.
https://xceed.com/xceed-words-for-net/
Thank you.

Hi,

"Xceed Words for .NET", the commercial version of DocX, will support .NET Core application on its next release v1.6.
https://xceed.com/xceed-words-for-net/
Thank you.

And will it also be supported on the free version?

As far as I got news.. No.

ζœ‰ζ²‘ζœ‰εΌ€ζΊηš„ε―ζ”―ζŒ.net core ηš„word η»„δ»Άε‘’οΌŸ