How to use SharePoint 2013 & 2016 to Convert to PDF
It is no secret that the real power of the Muhimbi PDF Converter for SharePoint comes from the ability to automate processes using workflows, it takes the human error factor out of the equation. Automatically convert, watermark and secure a file and write it to the Record Center when it changes? No problem, all fully automatic, nice, easy, repeatable, just what you need.
When the product was originally released customers were quick to request workflow support. First for SharePoint Designer Workflows, then Nintex Workflow followed by Visual Studio Workflows, K2 workflows and even in SharePoint Online. We were pretty pleased with ourselves, we support the whole lot across all SharePoint versions, well done to us…..
Then Microsoft introduced SharePoint 2013, which – in addition to the legacy workflow engine that we already support – comes with the optional Workflow Manager. You know… because things were just not complicated enough. This Workflow Manager only works on some SharePoint editions (not on SharePoint Foundation), must be deployed manually and uses a completely different architecture, who is going to use that? Well, it turns out that some people actually use it and – as we hate to say ‘no’ to our customers – we went back to the drawing board and hammered out support for Workflow Manager Workflows.
So, how does this work? Well pretty much the way you expect it to. When deploying the Muhimbi PDF Converter for SharePoint on SharePoint 2013, Central Admin’s Farm Solutions screen will show that a new Solution named ‘ muhimbi.pdfconverter.workflow
manager.sp2013.wsp’ has been deployed automatically. On systems that do not have the Workflow Manager installed this Solution is ignored, but those lucky enough to be running the Workflow Manager will see a range of new Workflow Activities in SharePoint Designer when selecting ‘SharePoint 2013 workflow’ as the Platform Type when creating a new workflow. Please note that this SharePoint Feature needs to be enabled at the Site (web) level where the workflow will be created.
Workflows using the SharePoint 2013 Workflow Platform Type now show the same range of PDF related workflow actions that are present for workflows using the SharePoint 2010 Workflow type. The only difference is that the legacy Convert to PDF workflow action is no longer present as this has been replaced by the more flexible Convert Document action.
Building a workflow is a matter of selecting the appropriate action and filling in the blanks. All actions are self-describing and do pretty much what you expect them to do. Links to the documentation for the SharePoint 2010 equivalents can be found below:
-
Convert Document: Convert document to PDF as well as non-PDF Files.
-
All watermark actions, excluding the Add Composite Watermark to PDF action.
-
Add Composite Watermark to PDF: Apply several watermarks in a single action.
-
Convert HTML to PDF: Convert HTML fragments or URLs such as List items or SharePoint Pages.
-
Convert to OCRed PDF: Make scans or faxes discoverable by your search engine.
-
Copy MetaData: Control which meta-data is copied when generating files.
-
Extract text using OCR: Carry out OCR on part of a page and return the text.
-
Merge Documents into PDF: Convert multiple files and merge them into a single PDF.
-
Secure PDF: Encrypt a file and restrict the ability to print or copy content.
-
Split PDF: Split a single, larger, file into multiple small ones.
It is possible to ‘chain’ multiple operations together by capturing the List Item ID of the output of one operation and use that to lookup an item, by its ID, in a follow up action. This way you can convert a document to PDF and then watermark or secure the generated PDF, all in a single workflow.
Most workflow actions require input or output files to be specified. For details about specifying file names and paths see this Knowledge Base Article.
SharePoint 2013 Workflow Manager workflows allow more complex scenarios than SharePoint 2010 workflows. For example it is possible to iterate over multiple files and convert them to individual PDFs, or build a list of file paths to feed into our Merge Documents into PDF action.
Additional details about working with Reusable and Site workflows can be found in this blog post.
Pretty cool stuff. If you have any questions then please leave a comment below or contact our friendly support desk, we love to help.
Clavin is a Microsoft Business Applications MVP who supports 1,000+ high-level enterprise customers with challenges related to PDF conversion in combination with SharePoint on-premises Office 365, Azure, Nintex, K2, and Power Platform mostly no-code solutions.