I am using MigraDoc + PDFsharp for generating a PDF (Salary slip). The PDF that is generated is by default vertical. (A4 - vertical).
I want it to be generated as Horizontal. What changes do I need to do?
I assume you want to know how to set page format to landscape.
PageSetup pageSetup = document.DefaultPageSetup.Clone();
// set orientation
pageSetup.Orientation = Orientation.Landscape;
// ... set other page setting you want here...
Assign that PageSetup to your section.
See also: How to Set Document Orientation (for All Pages) in MigraDoc Library?