Free Trial
Web API version
Licensing
Request A Quote
HAVE QUESTIONS OR NEED HELP? SUBMIT THE SUPPORT REQUEST FORM or write email to SUPPORT@BYTESCOUT.COM
Export To PDF | C#
Program.cs:
C#
using Bytescout.Spreadsheet; using System.IO; namespace XLS2PDF { class Program { static void Main(string[] args) { Spreadsheet document = new Spreadsheet(); // load table from existing XLS file document.LoadFromFile("SimpleReport.xls"); // add image document.Workbook.Worksheets[0].Pictures.Add(5, 1, "image.jpg"); // save as PDF bool autosize = false; document.SaveAsPDF("Output.pdf", autosize); // close the document document.Close(); } } }