Using Generator instead of Converter

Using Generator instead of Converter

Forum member · Sep 13, 2011
I have been spoiled. I have been using PDFConverter in evaluation mode to convert stored .RTF files into PDFs. However, my company is only going to purchase Core Suite for our customer. Is there a quick example someone can give that takes an already-loaded and stored .RTF file and converts it to .PDF using "Document.Draw"? I've looked through the examples, but I'm on a deadline. Hate to sound lazy, but this is a small piece of a much larger project. Thanks, Joel

Re: Using Generator instead of Converter

Support · Sep 13, 2011
Hello Joel, The Document.Draw method does not support converting RTF to PDF. In fact it is not possible to convert an RTF file to PDF using the CoreSuite. Thanks, ceTe Software Support Team

Re: Using Generator instead of Converter

Forum member · Sep 14, 2011
Can I take this one step further? I'm trying to determine if my company purchased the proper software modules for our client. Again, I've been using Core Suite and Converter in evaluation mode. What I need to do is use my code-behind to dynamically render an ASPX page. I have been using Converter to generate the PDF. Can I accomplish the same thing with Core Suite? Dim pdf As New PdfDocument(strCaseSummaryFilename) Dim mergeDocument As New MergeDocument(pdf) For i As Integer = 0 To mergeDocument.Pages.Count - 1 mergeDocument.Pages(i).Rotate = 270 Next Dim document As New Document() Dim page As New Page(ceTe.DynamicPDF.Conversion.PageSize.Legal, ceTe.DynamicPDF.Conversion.PageOrientation.Landscape) document.Pages.Add(page) Dim bytedata As Byte() = document.Draw() mergeDocument.Append(New PdfDocument(bytedata)) mergeDocument.Draw(strRotatedFilename) ' CurrentURL = "http://" & Request.Url.Authority.ToString() & "/ISG_Case_Monitoring/ViewReadyToBillCase_RPT.aspx?CASE_ID=" & Session("CASE_ID") CurrentURL = "http://" & Request.Url.Authority.ToString() & "/ViewReadyToBillCase_RPT.aspx?CASE_ID=" & Session("CASE_ID") Converter.Convert(CurrentURL, strFilename, conversionOptions) System.Threading.Thread.Sleep(1000) MergeFullCaseSummary = mergeDocument.Merge(System.IO.Path.Combine(strRotatedFilename), System.IO.Path.Combine(strFilename)) MergeFullCaseSummary.Title = Session("CASE_ID") & ConfigurationManager.AppSettings("DocumentType_FullCaseSummary") & ".pdf" MergeFullCaseSummary.Draw(strDocumentsFolder & "\" & MergeFullCaseSummary.Title) Thanks, Joel

Re: Using Generator instead of Converter

Support · Sep 14, 2011
Hello Joel, The code which you have posted shows that you are merging already existing PDF document and saving to disk. In second step you are converting web page using its URL and saving it to disk. Then in third step again you are combing these two outputs to make a single PDF document. The DynamicPDF Core Suite for .NET allows you to generate the PDF document from scratch and merge already existing PDFs and generate reports using data from data base. It is not possible to convert the webpage to PDF using DynamicPDF Core Suite for .NET product. For your scenario you will need two products DynamicPDF Merger for .NET to merge the already existing PDF documents and DynamicPDF Converter for .NET product to convert the webpage to PDF and save it to disk. Please refer the feature chart for the DynamicPDF Merger for .NET product at: httphttp://www.DynamicPDF.com/Products/DynamicPDFForNET/Merger/FeatureChart.csp . Also feel free to contact our sales team at: [^a|mailto: sales@cete.com |opennewiwndow|sales@cete.com ^] if you would like to have quote for purchase of both DynamicPDF Merger and Converter for .NET products. Thanks, ceTe Software Support Team.