PrintToPDF() JS Access Issue

  • 27 August 2018
  • 2 replies
  • 12 views

Badge +2

Nintex Community,

   Recently we ran into a strange occurrence using the javascript line:

      NWF$(document).ready(function(){NWF.FormFiller.PrintToPDF.PrintToPDF();});

   This javascript line is suppose to convert your Sharepoint form to a PDF and will open up the add in notification bar to open the PDF or Save it as shown below

IE PDF Notification Bar Image

When I have my coworkers try it or use my test ID is displays the Converting To PDF Sharepoint spinner box, but when it closes nothing happens. They do not get the notification bar, and nothing was saved in their downloads folder.  We decided to bring Desktop Support in to see if it was browser related, which was ruled out quickly.  It's also not the machine, as I can duplicate the issue with the test ID on my machine. 

We started digging into this issue, starting with internet search.  We found a few posts about making sure the users have at least reader access to your site.  It should not have affected my coworkers since they have the same access to the site collection I do, with full control.  So we ruled out the site collection, and or site permissions.

This prompted us to trace the network results of the button function for myself and the test ID.  Fro myself the network results return the following: 

/sites/ERA/Sandbox/_layouts/15/nintexforms/PrintPdf.aspx HTTPS POST 200

My Coworkers and the Test ID get the following:

/sites/Test/Sandbox/_layouts/15/nintexforms/PrintPdf.aspx POST 302
/sites/Test/Sandbox/_layouts/15/AccessDenied.aspx POST 200

This tells us it is an access issue.  We don't have access to SharePoint Farm so we can not check the PrintPDF.aspx.

I imagine this would be the next thing to check.  Has anybody run into this problem and is access to the PrintPDF that is the actual problem?  Is there something out we should check? 


2 replies

Badge +2

So we discovered this action works in QA and Prod so we are currently using this approach that works well in IE.  We are still looking at UAT to determine the root cause.  If we find out I will keep you posted.  It's currently not a priority on the admin side.  Hopefully they will let us know the root cause and we can update this post completely.

Badge +2

So we finally had one of the admins look into our development server issues, and this was their fix,  I believe when they say the "root site collection", they are talking about the Web App, the highest level of the SharePoint server.

"After giving “Everyone” with read access at root site collection level , I am able to generate pdf with my PNC account (non system account/admin)."

Reply