Subscribe to News feed

Securing PDF Files using SharePoint Designer Workflows

Posted at: 3:34 PM on 16 December 2010 by Muhimbi

combination_lockThe Muhimbi PDF Converter for SharePoint has had the ability to secure PDF files for quite some time, but it always required a separate product, which increased complexity, and more importantly cost.

We are happy to announce that as of version 4.1 the product now ships with a native SharePoint Designer Workflow Activity that allows security settings such as the Open Password, Owner Password and document restrictions such as Printing and Content Copying to be applied from a friendly SharePoint Designer workflow.

Update: As of version 6.0 it is possible to use the SharePoint User Interface to apply user specific security when a file is opened.

The best way to show how this works is by example. What follows is a walkthrough of how to create a SharePoint Designer Workflow to automatically apply security settings to any new or modified PDF file in a Document Library. In this example we use SharePoint Designer 2010, but it works just as well in SharePoint Designer 2007.

Before we begin, let’s have a look at the options provided by the new Secure PDF workflow activity.
 

Secure-Sentence

 
In typical Muhimbi fashion, the workflow sentence is consistent with our other Workflow Activities (e.g. Converting / watermarking), and is largely self-describing.

  1. this document: The document to apply the security settings to. For most workflows selecting Current Item will suffice, but some custom scenarios may require the look up of a different item. You may also want to check that the file type of the document is ‘pdf’ before trying to apply security.
     
  2. this file: The name and location of the secured file. Leave this field empty to overwrite the source file with the secured copy. Enter a path, including the Document Library and any folder names, to write the secured file to a separate location. E.g. “shared documents/secured files/confidential.pdf”. You can even specify a different site collection. 
     
  3. open password: When specified, anyone who wants to open the PDF file will need to enter this password.
     
  4. owner password: When specified, anyone who wants to change the security settings on the PDF file will need to enter this password.
     
  5. disable options: One or more restrictions to apply to the PDF file, separated by a pipe ‘|’ character . By default it applies all restrictions (Print|HighResolutionPrint|ContentCopy|Annotations|FormFields|ContentAccessibility|DocumentAssembly), but any combination is allowed. Enter the word Nothing to not apply any restrictions. In order to activate these settings you must supply an owner password.
     
  6. List ID: The ID of the list the secured file was written to. This can later in the workflow be used to perform additional tasks on the file such as a check-in or out.
     
  7. Item ID: The ID of the secured file. Can be used with the List ID.

 

imageProperties of a Secured PDF File.

 

Create the workflow as follows:

  1. Download and install the Muhimbi PDF Converter for SharePoint.  
     
  2. Make sure you have the appropriate privileges to create workflows on a site collection.
     
  3. Create a new workflow using SharePoint Designer.
     
  4. Associate the workflow with the library of your choice, tick the boxes next to both ‘Automatically start….’ options and proceed to the next screen.
     
  5. Because we are running the workflow when PDF files are created as well as modified, a new Yes/No column named Secured will need to be added to the document library using a default value of No. This way we can mark a document as secured and stop workflows from recursively triggering. Alternatively, if files are secured in place, you can decide to just trigger the workflow when new files are added.
     
  6. Design the workflow as per the following screen. In summary it does the following:
     
    • Check if the file is in PDF format. Otherwise security cannot be applied.
    • Check if the file has already been secured. If it has then it doesn’t need to be secured again.
    • The PDF File is secured in place. Both Open and Owner passwords are applied and all restrictions are set.
    • The file is marked as Secured so the workflow doesn’t repeatedly run.
    • A status message is written to the workflow history.
       

Security-Workflow

 

Publish the workflow and create / convert / upload a new PDF file in the Document Library. After a few seconds the workflow column will change to Completed, indicating that the file has been secured successfully.

.




Labels: , , , ,

Muhimbi ‘Features’ in Google AdWords movie

Posted at: 12:33 PM on 15 December 2010 by Muhimbi

We haven’t been too impressed with Google AdWords in the last year, between the massive amounts of click-fraud we have experienced as well as campaigns that were stopped without notice, but their 10th anniversary personalised movies are truly impressive.

I have included some screenshots below. Click here to see the entire movie.

10th-Aniversary

Labels:

Converting multiple SharePoint files to PDF Format using Nintex workflow

Posted at: 6:37 PM on 10 December 2010 by Muhimbi

Nintex logoAlthough I have only recently started using Nintex Workflow, I have completely fallen in love with it. What used to be painful to achieve in SharePoint Designer has become absolute child’s play when using Nintex Workflow, especially in combination with the PDF Converter For SharePoint’s native Nintex support.

In addition to the PDF Conversion Workflow Activity described in this post, Nintex activities for PDF watermarking, PDF security, PDF merging, HTML to PDF conversion and more.

Let’s illustrate the power of these combined tools using an example that is very difficult to achieve in SharePoint designer: Act on a set of list items. In this example, which took only 5 minutes to create, a workflow retrieves all files modified during the current day and converts them to PDF. Ideally you would schedule this workflow to run off-peak to batch process all new and modified files.

Please follow the instructions below or download the complete workflow in NWF format.
 

Multiple-filesThe finished workflow – BRILLIANT!

 

Prerequisites

Before we start building the workflow, please make sure all prerequisites are in place. It is also assumed that the reader has some knowledge of building Workflows using Nintex Workflow.

  1. Make sure the PDF Converter for SharePoint version 4.1 (or newer) is installed in line with chapter 2 of the included Administration Guide. 
     
  2. Naturally Nintex Workflow will need to be installed as well. Nintex Workflow version 2007, 2010 and 2013 are supported.
     
  3. Make sure the Muhimbi.PDFConverter.Nintex.WebApp SharePoint Feature is activated on the relevant Web Application using SharePoint Central Administration.
     
  4. The user (you) will need to have the appropriate privileges to create workflows.

 

 
 
Creating a new workflow

To get started, create a new workflow and choose the blank template. Make sure the workflow doesn’t start automatically and add the workflow variables listed in the following screenshot.

Workflow-Variables

Please make sure that the appropriate data types are assigned (They are listed between round brackets behind each variable name). The names are largely self describing, but some additional information is provided below:

  • Source Item ID: By default the item that triggered the workflow is converted to PDF format. However, as we are iterating over multiple items we need to specify the ID of the item to convert in this variable. In SharePoint 2010 / 2013 select Integer as the Type, not List Item ID.
     
  • Source List ID: The PDF Converter assumes the item that is being converted is located in the same list the workflow is attached to. However, if this is not the case then the ID (a GUID) of the list will need to be specified as well. In this example everything is located in the same list so this variable is not actually used.
     
  • Source Files: As we are potentially converting multiple files we need to define a variable of type Collection to hold the list of files we’ll be iterating over.
     
  • Generated PDF Item ID: Once a file has been converted to PDF, you may want to carry out additional actions on this new file, for example checking it in. Once converted, the ID of the PDF is automatically stored in this variable. In SharePoint 2010 / 2013 select Integer as the Type, not List Item ID. This example uses the (Legacy) Convert to PDF Workflow Activity, if you use the newer Convert Document activity then please take into account that the Generated PDF Item ID is of type Text. If you wish to pass this ID into a secondary activity then you may need to convert it to the correct data type using the Convert Value Workflow Activity. An example can be found here.
     
  • Generated PDF List ID: As the PDF Converter allows files to be written to different document libraries, and even completely different Site Collections, you may want to know the ID of the destination list.

 

Adding the workflow actions

We are now ready to add the actions to the workflow. Begin by adding a Query List action, which will allow us to retrieve all files modified today and store the results in the Source Files collection.

Query-List

Please fill out the settings for this action as in the screenshot listed above. You may want to add an additional filter rule to check that Content Type is not equal to Folder or Document Set.
 

Continue by adding the For Each action to the workflow. Specify the name of the collection to iterate over and the name of the variable to store the Item’s ID in.

For-Each

 

The next set of actions will all need to be added inside the For Each action, to make sure they are executed separately for each file in the list.

We want to make sure that we only invoke the PDF Converter for files that are not already in PDF format, so add a condition and check that the file type equals ‘pdf’ as per the following screenshot.

Set-Condition

 

Add the Convert file to PDF action listed under the Muhimbi PDF section to the No branch of the condition (type is not pdf). Fill it out as per the left most image in the following screenshot.

Convert-PDFThe PDF Converter integrates with Nintex Workflow 2007 & 2010.
 

You may want to leave the Destination Path empty, which will write the PDF File to the same location as the source file. For more information about the Destination Path or any of the other fields, hover the mouse over the small information icons.

The workflow is now done. You may want to add some tracking information using the Log In the History List action. In our example we use the following 2:

  • Last action in the No branch:
    List ID: {WorkflowVariable:Generated PDF List ID} - List Item ID: {WorkflowVariable:Generated PDF Item ID}
     
  • Last action in the Yes branch:
    Already in PDF Format: {WorkflowVariable:Source Item ID}

 

Running the workflow

Finalise the workflow by saving and publishing it, after which it is ready to be executed.

You can either run the workflow manually or schedule it to run at a time of your choice.

.




Labels: , , , , ,

Converting InfoPath, HTML, Word, Excel etc to PDF Format using Nintex Workflow

Posted at: 3:58 PM on 06 December 2010 by Muhimbi

Nintex logo

The Muhimbi PDF Converter for SharePoint has had the ability to be integrated in SharePoint workflows for a very long time. Our initial focus has been on the #1 workflow tool, SharePoint Designer, but today we are happy to announce support for everyone’s favourite workflow environment, Nintex Workflow.
 

Nintex-PDF-Conversion Nintex Dialog for the new PDF Conversion Action
 

Rather than just blindly porting a SharePoint Designer Workflow Action to Nintex, we have taken a step back and make it work the Nintex way. Nintex Lookups and Workflow Variables can be used and it is even possible to convert items other than the ones that triggered the workflow, which makes it ideal for converting entire sets of documents. For a comprehensive example, have a look at this post.

This new functionality is scheduled for inclusion in the upcoming 4.1 release of the PDF Converter for SharePoint. If you are interested in testing it out then please let us know..

.





Labels: , , , , , , ,

Need support from experts?

Access our Forum

Download Free Trials