GetDocument method problem

GetDocument method problem

Forum member · Jan 9, 2012
Hi, I am useing ceTe.DynamicPDF.20.dll Version 4.0.3.20. Using this i am converting Mutlipage tiff file to a PDF. I am using GetDocument() method of ceTe.DynamicPDF.Imaging.TiffFile class. But it always converts only one page i.e. first page. and some time i get error index out of range. Please provide your feedback as soon as possible i stuck with this problem. Thanks, shailesh

Re: GetDocument method problem

Support · Jan 9, 2012
Hello Shailesh, Please try using the latest version 4 dll file in your application and see if it works for you. You can download latest dll files by logging into our CustomerArea: http://www.DynamicPDF.com/CustomerArea using your version 4 product serial number. Remove reference for the old dll file and reference latest dll file in your application. If you continue getting error even after using the latest dll file then please send over input Tiff file, full stack trace of error message and the sample code which you are using to our support team at: [^a|mailto:support@cete.com|opennewiwndow|support@cete.com^] so that they can look into it further. Thanks, ceTe Software Support Team.

Re: GetDocument method problem

Forum member · Jan 9, 2012
Thanks for your quick response. It means the GetDocument method will return all the images from Multipage tiff file & used convert Multipage tif to PDF. Is it correct?

Re: GetDocument method problem

Support · Jan 9, 2012
Hello, Yes, the GetDocument method of the TiffFile class allows you to convert multipage Tiff file to PDF document. Thanks, ceTe Software Support Team.

Re: GetDocument method problem

Forum member · Jan 10, 2012
Hi, I have debugged it and found following error. Is there any solution for this except latest DLL? Error: {"Exception of type 'System.OutOfMemoryException' was thrown."} Stack Trace: at zz93.i7..ctor(TiffImageData A_0, jo A_1) at ceTe.DynamicPDF.Imaging.TiffImageData.a() at ceTe.DynamicPDF.Imaging.TiffImageData.b() at ceTe.DynamicPDF.Imaging.TiffImageData.Draw(PageWriter writer, Single pdfX, Single pdfY, Single width, Single height) at ceTe.DynamicPDF.PageElements.BackgroundImage.Draw(PageWriter writer) at ceTe.DynamicPDF.PageElements.Group.Draw(PageWriter writer) at ceTe.DynamicPDF.Page.b(PageWriter A_0) at ceTe.DynamicPDF.Page.DrawEntries(DocumentWriter writer, Int32 pageNumber, Int32 sectionPageNumber) at ceTe.DynamicPDF.Page.a(DocumentWriter A_0, Int32 A_1, Int32 A_2, Int32 A_3) at zz93.ab.d(Int32 A_0) at zz93.ab.v() at ceTe.DynamicPDF.Document.Draw(String filePath) at PDFConvertor.PDFConvertor.ConvertPDF(String& TIFFile)

Re: GetDocument method problem

Support · Jan 10, 2012
Hello, Please send over the input Tiff image, build number of the DynamicPDF dll file which your application is referencing(If you can't able to make our the exact build number of the dll file then send over the dll file) and the sample code which you are using to our support team at: [^a|mailto:support@cete.com|opennewiwndow|support@cete.com^]. This information will help them to do some testing to find the exact cause for this error. Thanks, ceTe Software Support Team.

Re: GetDocument method problem

Forum member · May 10, 2012
Hi we are using the same dll, we have list of tiff files with potrait and landscape and trying to make it as pdf. But got the following error at zz93.ag.a() at zz93.ag..ctor(Byte[] A_0, Int32 A_1) at zz93.i5..ctor(TiffImageData A_0, jn A_1) at ceTe.DynamicPDF.Imaging.TiffImageData.a() at ceTe.DynamicPDF.Imaging.TiffImageData.b() at ceTe.DynamicPDF.Imaging.TiffImageData.Draw(PageWriter writer, Single pdfX, Single pdfY, Single width, Single height) at ceTe.DynamicPDF.PageElements.BackgroundImage.Draw(PageWriter writer) at ceTe.DynamicPDF.PageElements.Group.Draw(PageWriter writer) at ceTe.DynamicPDF.Page.b(PageWriter A_0) at ceTe.DynamicPDF.Page.DrawEntries(DocumentWriter writer, Int32 pageNumber, Int32 sectionPageNumber) at ceTe.DynamicPDF.Page.a(DocumentWriter A_0, Int32 A_1, Int32 A_2, Int32 A_3) at zz93.aa.d(Int32 A_0) at zz93.aa.v() at ceTe.DynamicPDF.Document.Draw(Stream stream) Code: public static void Tiff2Pdf(Image[] images, Stream stream) { PageList pageList = new PageList(); TiffFile tiffFile = null; try { for (int i = 0; i < images.Length; i++) { // Create a TiffFile object from the TIFF image tiffFile = new TiffFile(images[i].ImageData); TiffImageData data = tiffFile.Images[0]; pageList.Add(data.GetPage(0F)); } ceTe.DynamicPDF.Document document = CreateDocument(); document.Pages.Append(pageList); // Save the PDF document document.Draw(stream); } catch (Exception) { throw; } finally { if (tiffFile != null) tiffFile.Close(); } } Request you to let us know, can we create pdf out of set of tiffs which are landscape and potrait or of different diemensions? This is a prodction request you provide the quick reponse.

Re: GetDocument method problem

Support · May 10, 2012
Hello, Yes, you should be able to create the PDF out of a TIFF image using TiffFile.GetDocument method. Try using the latest available build by downloading it from the customer area . If you continue getting this error in the latest build, please email the following information along with the URL of this forum post to [^a|mailto:support@cete.com|opennewwindow|support@cete.com^] so we can look into this issue further. 1. Input Tiff images causing this error. 2. Version and build number of the DynamicPDF dll Thanks, ceTe Software Support Team.

Re: GetDocument method problem

Support · May 31, 2012
Hello, The error discussed above was caused in an older build of DynamicPDF v4.0.3 dll and was resolved by using the latest build dll of the same version. If anyone else is using this version and get the same error as above please download the latest build from the customer area by logging in with the v4 serial number. Thanks, ceTe Software Support Team.