Skip to content
This repository has been archived by the owner on Nov 24, 2020. It is now read-only.

Word document from .dotx Template #164

Open
FelixHerz opened this issue Feb 7, 2020 · 0 comments
Open

Word document from .dotx Template #164

FelixHerz opened this issue Feb 7, 2020 · 0 comments

Comments

@FelixHerz
Copy link

Hey, I'd like to know how to create a word document, starting from a Word .dotx template.

The following code lead to an Error EOF in header

using (var fs = new FileStream("C:\\tmp\\" + _template1, FileMode.Open, FileAccess.Read))
{
    XWPFDocument doc = new XWPFDocument(fs);
    // ....
   
    var dataStream = new MemoryStream();
    doc.Write(dataStream);
    return dataStream;
}

Any help would be highly appreciated.

Cheers, Felix

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant