I hope it makes sense. Need help to remove the appending TotalCount to page footer text as I am placing different text in the footer. I just updated one line in the OnCloseDocument method, I removed the -1 to the writer. You are using iText 5 for.
|Published (Last):||27 August 2015|
|PDF File Size:||7.23 Mb|
|ePub File Size:||13.41 Mb|
|Price:||Free* [*Free Regsitration Required]|
I went through the internet to get the best option for PDF generation, of-course I am a big fan of Crystal Reports for PDF generation not only for its simplicity but also for its quality. But the problem with Crystal Reports is that it should be installed on your hosting server to work with your website.
After going through many articles on the internet, I was able to generate an invoice as I expected. Background I will start with the requirements. To use itextSharp, you need to download the iTextSharp library as it is available for free. You can download it from here. Use the following namespace before you start writing your code: using iTextSharp. A4 ; System. FileStream Server. Red ; cell. AddCell "R1C1" ; tab.
AddCell "R1C2" ; tab. AddCell "R2C1" ; tab. AddCell "R2C2" ; tab. Add new iTextSharp. Add "Unorder List 2" ; pdfList. Add "Unorder List 3" ; pdfList. Add "Unorder List 4" ; cell. AddElement pdfList ; tab. AddCell cell ; doc. Add tab ; doc. Close ; file. AddCell cell ; tabFot. WriteSelectedRows 0, -1, , document. Top , writer. Bottom, writer. GetInstance doc, str ; Response. BinaryWrite str. ToArray ; str. Close ; Response. End ;.
使用ASP .NET (C#) 產生PDF檔的好幫手—iTextSharp library (上)
Generating PDF using ItextSharp with Footer in C#