Mahesh Bodepudi

Mahesh Bodepudi

  • NA
  • 90
  • 54.7k

How to add Page numbers,header and footer to pdf document

Sep 25 2017 7:14 AM
Hi,
I have to add header and footer to a pdf document.I am using MVC4 and rendering view to pdf document and downloading by using ITextSharp.Now I am using the below code 
 
public ActionResult DownloadPDF(string shipId)
{
var report = new ActionAsPdf("ExporttoPDF", new { shipId = shipId });
return report;
}
 
Could any one please help me how to add header and footer while downloading the pdf through code. 

Answers (4)