I'm trying to create a exportable/printable page with RotativaPDF where those pages must have a small section with some data from a customer, tables with customer credits and payments, and every page must have a footer and a header (excluding the first page).
My controller's action:
public ActionResult ExportToPDF()
{
var customer= new Customer();
var customerData = string.Format("Name: {0} | Client Nr.: {1}", customer.Name, customer.CardNumber);
return new ActionAsPdf("ExportPDF")
{
CustomSwitches = "--footer-right \"[page]/[topage]\" " +
"--footer-left \"Emission date: [date]\" " +
"--header-right \""+ customerData + "\" " +
"--header-left \"Customer Data\" " +
"--footer-font-size \"11\" " +
"--header-font-size \"11\" " +
"--footer-spacing \"10\" " +
"--header-spacing \"20\""
};
}
Note: I defined CustomSwitches like is described on this link.
With my code, all the pages presents a header. How should I do to not present a header on the first page?
Expected result: