cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
dperani
Nintex Newbie

Print button that also validates

We are trying to get a print button that will also validate before printing as we have some forms that still require a signature (cannot use workflow approval).  We have tried using windows.print() however we have issues with the form fitting on one page.  Either the right side is cuttoff or we use fitt to page and it is really small.  Also, it requires teh end user to not print the header and footer of the web page (cannot rely on them).

We have tried using the Print to PDF line  NWF.FormFiller.PrintToPDF.PrintToPDF(); this doesn't work well in that if all fields validate fine it does not go to the PDF since it is saving the form to the Sharepoint List/Library and it is now closed.  It only works if their is a required field that has no data....hmmm what else???

Labels: (2)
Tags (2)
0 Kudos
Reply
4 Replies
b_dheeraj
Nintex Newbie

Re: Print button that also validates

Try adding this script to the button which will prompt the user to print. They can also SAVE the file as a PDF too.

function printMonsterForm()
{
var curURL = window.location.href;
//alert("curURL:"+ curURL);
curURL = curURL+"&isdlg=1";

var curWin = window.open(curURL);
}

0 Kudos
Reply
Automation Master
Automation Master

Re: Print button that also validates

Can you add a button control that has the setting to Cause Validation, and it call window.print? Also, you can set print media css using (at)Print media query to hide/move areas of the form. CSS3 Media Queries 

0 Kudos
Reply
dperani
Nintex Newbie

Re: Print button that also validates

Hi Dheeraj,

Where is the print command called?

Dawn

0 Kudos
Reply
Automation Master
Automation Master

Re: Print button that also validates

The javascript button would call the window.print.

0 Kudos
Reply