Click here to Skip to main content
15,897,891 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,
I am trying to Print Gridview data with Extra Info Like Receipt Asp.Net

I am using Print code

C#
grdReport.RenderControl(hw);


building string data and using js to print.

Print is working fine but i am unable to add extra details like company name on top and address at bottom.

In c# Asp .Net
Posted

Thnx @ Christian Graus

completed with javascript kept a hidden div

and printed by unhiding it and then kept it hidden

C#
new_window.document.write(header.outerHTML);
               new_window.document.write(grd_obj.outerHTML);
               new_window.document.close();
               new_window.print();
 
Share this answer
 
I don't understand why you need 'print code'. You just need a window that shows exactly what you want to print and calls window.print in javascript. You can add any info you want, it will all print.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900