Re: [iText-questions] PDF file size limit in iText
Hi, a patch for this has been submitted by WMJ http://itext-general.2136553.n4.nabble.com/Can-t-open-or-write-very-large-PDF-files-td3997140.html and was integrated into iText Version 5.2.0 http://itextpdf.com/history/?branch=52node=520 Regards, ToM 2013/5/6 naveen ks naveen...@gmail.com Hi All, I have a requirement to process PDF files of larrge size (2GB+) and I was reading that iText 2.x had a limitation on the file size to 2GB. Can anyone let me know if this limitation still exists in iText 4.2 or 5.x Regards, Nvn -- Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET Get 100% visibility into your production application - at no cost. Code-level diagnostics for performance bottlenecks with 2% overhead Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap1 ___ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions iText(R) is a registered trademark of 1T3XT BVBA. Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/ Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php -- Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET Get 100% visibility into your production application - at no cost. Code-level diagnostics for performance bottlenecks with 2% overhead Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap1___ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions iText(R) is a registered trademark of 1T3XT BVBA. Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/ Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php
Re: [iText-questions] PDF file size limit in iText
The limitation was lifted in 5.2.0. Paulo On Mon, May 6, 2013 at 9:41 AM, naveen ks naveen...@gmail.com wrote: Hi All, I have a requirement to process PDF files of larrge size (2GB+) and I was reading that iText 2.x had a limitation on the file size to 2GB. Can anyone let me know if this limitation still exists in iText 4.2 or 5.x Regards, Nvn -- Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET Get 100% visibility into your production application - at no cost. Code-level diagnostics for performance bottlenecks with 2% overhead Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap1 ___ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions iText(R) is a registered trademark of 1T3XT BVBA. Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/ Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php -- Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET Get 100% visibility into your production application - at no cost. Code-level diagnostics for performance bottlenecks with 2% overhead Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap1 ___ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions iText(R) is a registered trademark of 1T3XT BVBA. Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/ Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php
Re: [iText-questions] PDF file size limit in iText
Op 6/05/2013 10:58, TvT schreef: and was integrated into iText Version 5.2.0 http://itextpdf.com/history/?branch=52node=520 But that first implementation contains serious flaws, so all 5.2.x versions were removed from SourceForge. The problem that causes 5.2.x to fail was fixed in 5.3.0. -- Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET Get 100% visibility into your production application - at no cost. Code-level diagnostics for performance bottlenecks with 2% overhead Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap1 ___ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions iText(R) is a registered trademark of 1T3XT BVBA. Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/ Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php
[iText-questions] [SPAM] Re: PDF file size limit in iText
Nvn, naveen ks wrote I have a requirement to process PDF files of larrge size (2GB+) and I was reading that iText 2.x had a limitation on the file size to 2GB. Can anyone let me know if this limitation still exists in iText 4.2 or 5.x As others have already answered the intrinsic limitation at 2GB has been lifted in 5.2.0 and finally fixed in 5.3.0. Please be aware, though, that this does not mean you can handle a 4GB PDF like any small 100KB one. You should take care and use constructors that don't hold the whole file in memory but instead read objects only when they are needed using random access and store manipulated or newly created ones early to disc. Furthermore you even then have to be prepared to have quite some memory at hand as generally at least the cross references and some structure defining objects are read completely into memory which already can amount to a lot of memory. Regards, Michael -- View this message in context: http://itext-general.2136553.n4.nabble.com/PDF-file-size-limit-in-iText-tp4658184p4658188.html Sent from the iText - General mailing list archive at Nabble.com. -- Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET Get 100% visibility into your production application - at no cost. Code-level diagnostics for performance bottlenecks with 2% overhead Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap1 ___ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions iText(R) is a registered trademark of 1T3XT BVBA. Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/ Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php
Re: [iText-questions] PDF file size limit in iText
My requirement is to read the 2-3GB file sequentially (in order of bookmarks), extract contents w.r.t bookmarks and create the smaller PDF based on previous result. I believe to read the large PDF, I need to use input stream as below. InputStream inputStream = new FileInputStream(INPUTFILE); PdfReader reader = new PdfReader(inputStream); ListHashMaplt;String, Object bookmarks = SimpleBookmark.getBookmark(reader); Please let me know if the above requirement is feasible with iText 4.2x or I will need to use iText 5.x version. Regards, Naveen -- View this message in context: http://itext-general.2136553.n4.nabble.com/PDF-file-size-limit-in-iText-tp4658184p4658189.html Sent from the iText - General mailing list archive at Nabble.com. -- Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET Get 100% visibility into your production application - at no cost. Code-level diagnostics for performance bottlenecks with 2% overhead Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap1 ___ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions iText(R) is a registered trademark of 1T3XT BVBA. Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/ Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php
Re: [iText-questions] PDF file size limit in iText
Op 6/05/2013 14:19, Nvn schreef: Please let me know if the above requirement is feasible with iText 4.2x or I will need to use iText 5.x version. In your case, it would even be better to use iText 5.4.x as it has better IO handling than the previous versions. In any case: you can't use versions prior to iText 5.3.x if you need to process files 2 GB. -- Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET Get 100% visibility into your production application - at no cost. Code-level diagnostics for performance bottlenecks with 2% overhead Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap1 ___ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions iText(R) is a registered trademark of 1T3XT BVBA. Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/ Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php
[iText-questions] data:image/bmp;base64 to pdf question
Hi everyone, quick question. Does anyone know how to convert a data:image/bmp;base64 from a html page to a pdf via iText? Anil George Senior Web Developer HEALTHWORKS a division of PASSPORTHEALTH COMMUNICATIONS INC. 1265 Drummers La., Suite 202 Wayne, PA 19087 610-994-0302 610-354-0900 ext. 302 (Toll Free) anil.geo...@passporthealth.com http://www.passporthealth.com CONFIDENTIALITY NOTICE: This e-mail communication and all attachments are for the sole use of the intended recipient(s) and may contain confidential and privileged information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by replying to this e-mail message and delete all copies and attachments of the original message. -- Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET Get 100% visibility into your production application - at no cost. Code-level diagnostics for performance bottlenecks with 2% overhead Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap1 ___ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions iText(R) is a registered trademark of 1T3XT BVBA. Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/ Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php
Re: [iText-questions] data:image/bmp;base64 to pdf question
I use this in my website but Im getting the tiff images from DB as Byte may it help you if (memoryStream != null) { var imageFile = System.Drawing.Image.FromStream(memoryStream); var frameDimensions = new System.Drawing.Imaging.FrameDimension(imageFile.FrameDimensionsList[0]); var numberOfFrames = imageFile.GetFrameCount(frameDimensions); var paths = new string[numberOfFrames]; for (int intFrame = 0; intFrame numberOfFrames; ++intFrame) { imageFile.SelectActiveFrame(frameDimensions, intFrame); var bmp = new Bitmap(imageFile); iTextSharp.text.Image img = iTextSharp.text.Image.GetInstance(bmp, System.Drawing.Imaging.ImageFormat.Bmp); // scale the image to fit in the page img.ScaleAbsolute(pdfDoc.PageSize.Width, pdfDoc.PageSize.Height); pdfDoc.Add(img); pdfDoc.SetMargins(1, 1f, 1f, 1f); pdfDoc.NewPage(); bmp.Dispose(); } On 6 May 2013 16:26, Anil George anil.geo...@passporthealth.com wrote: Hi everyone, quick question. Does anyone know how to convert a data:image/bmp;base64 from a html page to a pdf via iText? Anil George Senior Web Developer HEALTHWORKS a division of PASSPORTHEALTH COMMUNICATIONS INC. 1265 Drummers La., Suite 202 Wayne, PA 19087 610-994-0302 610-354-0900 ext. 302 (Toll Free) anil.geo...@passporthealth.com http://www.passporthealth.com CONFIDENTIALITY NOTICE: This e-mail communication and all attachments are for the sole use of the intended recipient(s) and may contain confidential and privileged information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by replying to this e-mail message and delete all copies and attachments of the original message. -- Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET Get 100% visibility into your production application - at no cost. Code-level diagnostics for performance bottlenecks with 2% overhead Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap1 ___ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions iText(R) is a registered trademark of 1T3XT BVBA. Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/ Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php -- Best Regards --- *Mohammed Hashem* Web Developer @ ArabSea. www.arabsea.com 00966 - 538 766 152 -- Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET Get 100% visibility into your production application - at no cost. Code-level diagnostics for performance bottlenecks with 2% overhead Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap1___ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions iText(R) is a registered trademark of 1T3XT BVBA. Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/ Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php
Re: [iText-questions] data:image/bmp;base64 to pdf question
Awesome! Thank you so much. I have another question though, can you do the pdfdoc.add at a particular area in the document? Anil George Senior Web Developer [cid:image001.png@01CE4A3E.0ED10450]HEALTHWORKS a division of PASSPORTHEALTH COMMUNICATIONS INC. 1265 Drummers La., Suite 202 Wayne, PA 19087 610-994-0302 610-354-0900 ext. 302 (Toll Free) anil.geo...@passporthealth.commailto:anil.geo...@passporthealth.com http://www.passporthealth.comhttp://www.passporthealth.com/ CONFIDENTIALITY NOTICE: This e-mail communication and all attachments are for the sole use of the intended recipient(s) and may contain confidential and privileged information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by replying to this e-mail message and delete all copies and attachments of the original message. From: Mohammed AlSayani [mailto:mohammed.alsay...@gmail.com] Sent: Monday, May 06, 2013 9:33 AM To: Post all your questions about iText here Subject: Re: [iText-questions] data:image/bmp;base64 to pdf question I use this in my website but Im getting the tiff images from DB as Byte may it help you if (memoryStream != null) { var imageFile = System.Drawing.Image.FromStream(memoryStream); var frameDimensions = new System.Drawing.Imaging.FrameDimension(imageFile.FrameDimensionsList[0]); var numberOfFrames = imageFile.GetFrameCount(frameDimensions); var paths = new string[numberOfFrames]; for (int intFrame = 0; intFrame numberOfFrames; ++intFrame) { imageFile.SelectActiveFrame(frameDimensions, intFrame); var bmp = new Bitmap(imageFile); iTextSharp.text.Image img = iTextSharp.text.Image.GetInstance(bmp, System.Drawing.Imaging.ImageFormat.Bmp); // scale the image to fit in the page img.ScaleAbsolute(pdfDoc.PageSize.Width, pdfDoc.PageSize.Height); pdfDoc.Add(img); pdfDoc.SetMargins(1, 1f, 1f, 1f); pdfDoc.NewPage(); bmp.Dispose(); } On 6 May 2013 16:26, Anil George anil.geo...@passporthealth.commailto:anil.geo...@passporthealth.com wrote: Hi everyone, quick question. Does anyone know how to convert a data:image/bmp;base64 from a html page to a pdf via iText? Anil George Senior Web Developer HEALTHWORKS a division of PASSPORTHEALTH COMMUNICATIONS INC. 1265 Drummers La., Suite 202 Wayne, PA 19087 610-994-0302 610-354-0900 ext. 302 (Toll Free) anil.geo...@passporthealth.commailto:anil.geo...@passporthealth.com http://www.passporthealth.com CONFIDENTIALITY NOTICE: This e-mail communication and all attachments are for the sole use of the intended recipient(s) and may contain confidential and privileged information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by replying to this e-mail message and delete all copies and attachments of the original message. -- Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET Get 100% visibility into your production application - at no cost. Code-level diagnostics for performance bottlenecks with 2% overhead Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap1 ___ iText-questions mailing list iText-questions@lists.sourceforge.netmailto:iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions iText(R) is a registered trademark of 1T3XT BVBA. Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/ Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php -- Best Regards --- Mohammed Hashem Web Developer @ ArabSea. www.arabsea.comhttp://www.arabsea.com 00966 - 538 766 152 inline: image001.png-- Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET Get 100% visibility into your production application - at no cost. Code-level diagnostics for performance bottlenecks with 2% overhead Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap1___ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions iText(R) is a registered trademark of 1T3XT BVBA.
Re: [iText-questions] data:image/bmp;base64 to pdf question
I think there is method to do it ..Actualy I dont have much experies in Itextsharp but I m creating complex tables and I but the valus inside it the add to PdfDoc, This is an example I hope will help you Rectangle r = new Rectangle(829, 560); Document pdfDoc = new Document(PageSize.A4.Rotate()); PdfWriter writer = PdfWriter.GetInstance(pdfDoc, Page.Response.OutputStream); // writer.PageEvent = new MyFooter(); pdfDoc.SetMargins(30f, 30f, 1f, 1f); pdfDoc.Open(); for (int i = 0; i = dgvEmployee.Rows.Count; i = i + 12) { iTextSharp.text.pdf.PdfPTable maintable = new iTextSharp.text.pdf.PdfPTable(1); maintable.WidthPercentage = 105; iTextSharp.text.pdf.PdfPCell headercell = new iTextSharp.text.pdf.PdfPCell(headeetable());// here I add Table headercell.FixedHeight = 120; headercell.Border = 0; headercell.HorizontalAlignment = 1; maintable.AddCell(headercell); iTextSharp.text.pdf.PdfPCell maincell = new iTextSharp.text.pdf.PdfPCell(datatable(i)); // also here add Table maintable.AddCell(maincell); iTextSharp.text.pdf.PdfPCell footercell = new iTextSharp.text.pdf.PdfPCell(footertable()); // also here add Table footercell.FixedHeight = 150; footercell.Border = 0; maintable.AddCell(footercell); pdfDoc.Add(maintable); pdfDoc.SetMargins(30f, 30f, 1f, 1f); pdfDoc.NewPage(); } pdfDoc.Close(); Page.Response.ContentType = application/pdf; Page.Response.AddHeader(content-disposition, attachment;filename= + DateTime.Now.Day + _ + DateTime.Now.Month + _ + DateTime.Now.Year + .pdf); Page.Response.Cache.SetCacheability(HttpCacheability.NoCache); Page.Response.Write(pdfDoc); Page.Response.End(); = private PdfPTable headeetable() { Font arabicfont = new Font(nationalBase, 13f, Font.NORMAL); //- frist the lif side table- iTextSharp.text.pdf.PdfPTable tablelift = new iTextSharp.text.pdf.PdfPTable(3); tablelift.WidthPercentage = 30; tablelift.RunDirection = PdfWriter.RUN_DIRECTION_RTL; //- End First Row- //- Start 2ed row- Paragraph Pheader = new Paragraph(new Phrase(but your fix values here , arabicfont)); Pheader.Add(Chunk.NEWLINE); Pheader.Add(new Phrase(but your fix values here , arabicfont)); iTextSharp.text.pdf.PdfPCell cell4 = new iTextSharp.text.pdf.PdfPCell(Pheader); cell4.RunDirection = PdfWriter.RUN_DIRECTION_RTL; cell4.FixedHeight = 80; cell4.Border = 0; cell4.HorizontalAlignment = 0; tablelift.AddCell(cell4); iTextSharp.text.Image gif = iTextSharp.text.Image.GetInstance(Server.MapPath(../../Images/MOClogo.jpg)); gif.ScaleAbsolute(130, 80); iTextSharp.text.pdf.PdfPCell cell2 = new iTextSharp.text.pdf.PdfPCell(gif); cell2.RunDirection = PdfWriter.RUN_DIRECTION_RTL; cell2.FixedHeight = 80; cell2.Border = 0; cell2.HorizontalAlignment = 1; tablelift.AddCell(cell2); string st =but your fix values here + Session[CountryName].ToString(); Paragraph PheaderR = new Paragraph(new Phrase(st, arabicfont)); PheaderR.Add(Chunk.NEWLINE); PheaderR.Add(new Phrase(but your fix values here , arabicfont)); iTextSharp.text.pdf.PdfPCell cell6 = new iTextSharp.text.pdf.PdfPCell(PheaderR); cell6.RunDirection = PdfWriter.RUN_DIRECTION_RTL; cell6.FixedHeight = 80; cell6.Border = 0; cell6.HorizontalAlignment = 1; tablelift.AddCell(cell6); //- end 2ed Row- //- Start 3ed row- st = Diplomate Salaries + Session[EmbassyName].ToString() + لشهر + Session[DipSalMonth].ToString() + + Session[DipSalYear].ToString(); iTextSharp.text.pdf.PdfPCell cell7 = new iTextSharp.text.pdf.PdfPCell(new Phrase(st, arabicfont)); cell7.RunDirection = PdfWriter.RUN_DIRECTION_RTL; cell7.FixedHeight = 35; cell7.Border = 0; cell7.Colspan = 3; cell7.HorizontalAlignment = 1; tablelift.AddCell(cell7); return tablelift; On 6 May 2013 16:42, Anil George