Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"document.xml could not be found" for SharePoint files #131

Closed
speedpro opened this issue Jun 4, 2020 · 5 comments · Fixed by #132
Closed

"document.xml could not be found" for SharePoint files #131

speedpro opened this issue Jun 4, 2020 · 5 comments · Fixed by #132
Assignees
Labels

Comments

@speedpro
Copy link
Contributor

speedpro commented Jun 4, 2020

I''m trying to use this for documents hosted on SharePoint, and I keep getting a "document.xml not found" error when I try to run createReport(). I seem to recall that sharepoint uses a document2.xml instead of document.xml

I did a search & replace inside /node_modules for this module ("document.xml" -> "document2.xml") and everything seemed to work after that.

I'm not sure how much work it would be to update the source code to support this format, but I'd be happy to submit a PR if you could point me in the right direction for a dev setup.

@speedpro
Copy link
Contributor Author

speedpro commented Jun 4, 2020

Also, refer to open-xml-templating/docxtemplater#366 where I encountered the same issue

@jjhbw
Copy link
Collaborator

jjhbw commented Jun 6, 2020

Thanks for this report! Reading the issue you linked, it appears this is also the case for Word Online / Office 365 files. Obviously we want to be able to support those, so i'll classify this as a bug.

@jjhbw jjhbw self-assigned this Jun 6, 2020
@jjhbw jjhbw added the bug label Jun 6, 2020
@jjhbw
Copy link
Collaborator

jjhbw commented Jun 6, 2020

@speedpro do you have an example of such a file? I'm trying to get access to the relevant MS software, but until then it would be useful to have an example.

@jjhbw
Copy link
Collaborator

jjhbw commented Jun 6, 2020

@speedpro never mind, found an example in the issue you linked. 🙏

@jjhbw
Copy link
Collaborator

jjhbw commented Jun 6, 2020

@speedpro This should do it. I'll incorporate this fix in the next point release.

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

Successfully merging a pull request may close this issue.

2 participants