To print gridview used javascript is :
function CallPrint() {
var prtContent = document.getElementById("divPrint");
var WinPrint = window.open('', 'prtContent ', 'left=100,top=100,width=100,height=100,tollbar=0,scrollbars=1,status=0,resizable=1');
datagridview.Columns[0].Visible = false;
WinPrint.document.write(prtContent.innerHTML);
WinPrint.document.close();
WinPrint.focus();
WinPrint.print();
WinPrint.close();
}
I would suggest you consider the following approach for printing multiple certificates:
1. One the original page (with Gridview), provide checkbox to let user choose the rows to print
2. When the user click a print button, the page will postback, and you can find all the selected rows(by looping the gridview to check checkbox
values) and redirect the user to a new page which will only display those selected rows.
3. thus, on the new page the user can print what they exactly want. Just an idea of generate a print version. How do you think?
Mark This Response as Answer
--
Chandu
http://www.dotnetfunda.com/images/dnfmvp.gif
Shitalr, if this helps please login to Mark As Answer. | Alert Moderator