We are yet to purchase Document Generation and forever finding ways to produce documents from list items. We also don't have Print to PDF for Nintex Forms as we are on standard license, so it all requires rather a lot of work. Some of the options we have considered in the past are, but not limited to:
- Document library with columns and quick parts - passing the information from the list into the document library columns and using quick parts inside the document library to populate the document. The workflow simply uses "create item" and adds the associated columns
- Document library with content controls - use create item from the list to create a document in a library, and then use "update document" action in the workflow to update the content controls
- SSRS reports - use reports to look at the list item data that can then be exported to word, pdf as required
I recently tried both document library approaches to create a document using a template from workflow and both kept giving me this error when opening in Word:
"We're sorry. We can't open test because we found a problem with its contents"
Details: No error detail available
I thought it was the order in which the document was being created and updated. Or the information that was being passed in. I raised a support ticket and we decided it was the table of contents causing the issue. This issue has recently been fixed so we upgraded workflow to no avail. I wasted days and days and grew a few (more) grey hairs. Then my lovely colleague and friend, Tosin, noticed that my document template attached to the document library was dotx format (word template). This seems perfectly reasonable right? Apparently not with this type of work. I re-created my templates; one with quick parts and the other with content controls to be docx format. And voila - they both work! I haven't seen anyone mention anything like this on the community so I thought I should blog about it so that I can hopefully save others the stress I have had for the past couple of weeks (and also so that I don't forget next time I have a requirement like this).
Roll on the purchase of Document Generation!!