You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: Document-Processing/Excel/Conversions/Excel-to-PDF/NET/Excel-to-PDF-Conversion.md
+96Lines changed: 96 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1809,6 +1809,102 @@ End Using
1809
1809
1810
1810
A complete working example to convert an Excel workbook to PDF by setting the paper size for all worksheets in C# is present on <ahref="https://github.com/SyncfusionExamples/XlsIO-Examples/tree/master/Excel%20to%20PDF/Page%20Setup%20Options/.NET/Paper%20Size">this GitHub page</a>.
1811
1811
1812
+
### Orientation
1813
+
1814
+
The following code illustrates how to convert an Excel workbook to PDF by setting the page orientation.
Dim converter As ExcelToPdfConverter = New ExcelToPdfConverter(workbook)
1896
+
1897
+
'Convert the Excel document to PDF with converter settings
1898
+
Dim pdfDocument As PdfDocument = converter.Convert(settings)
1899
+
1900
+
'Save the workbook as PDF
1901
+
pdfDocument.Save("Output.pdf")
1902
+
End Using
1903
+
{% endhighlight %}
1904
+
{% endtabs %}
1905
+
1906
+
A complete working example to convert an Excel workbook to PDF by setting the page orientation in C# is present on <ahref="https://github.com/SyncfusionExamples/XlsIO-Examples/tree/master/Excel%20to%20PDF/Page%20Setup%20Options/.NET/Orientation">this GitHub page</a>.
0 commit comments