Solved

Dynamic PDF files with ASP and FDF

Posted on 2004-09-27
7
426 Views
Last Modified: 2012-06-27
HI,

I'm new to FDF and PDF. I have a report I need to generate and put in a PDF format. I'm using ASP to get the data from the database. My only problem is that some sections will need to be repeated. For example, A person might have 3 different cars listed on the report but I need to account for the possibility of them having at most 10 and at least 1, is there any looping like structure available to use which would repeat a section of the PDF document so I can have 1 PDF document and it will account for all the numbers of cars? I also have a large text field which needs to be returned, is there a way to set up a field in the PDF document which will take a large amount of text and word wrap it within a specific space?

Thanks,

Darksbane
0
Comment
Question by:Darksbane
  • 4
  • 2
7 Comments
 
LVL 44

Expert Comment

by:Karl Heinz Kremer
ID: 12161604
You should use something like iText.NET (http://itextdotnet.sourceforge.net/en/) to create your PDF documents. This way, you can use all the control mechanism that you have available in ASP to create your PDF document.
Look at teh web site, they have examples for what's possible with iText (.NET).

You could use form fields to solve your problem, but because you are doing this on the server, it would be pretty complicated to get the template feature to work. In Acrobat (not the free Reader) you can create multiple instances of a page by using the page template feature. Whenever you need to start a new record, you would just add one or more new pages to the document and fill in the form fields.
Acrobat (the full version) cannot be used on a server (see the EULA for more information).
This means that you would need a FDF merger/flattener that does support templates.

I will look around to see if any of the packages I'm familar with support templates.
0
 
LVL 44

Expert Comment

by:Karl Heinz Kremer
ID: 12161608
And, a normal text form field will do word wrapping.
0
 
LVL 2

Author Comment

by:Darksbane
ID: 12162315
I looked at the link, is there anything in regular asp which is similar? We would like to stay away from .net since the rest of our site is in regular ASP. Also is there a way to force a newline in the data passed over in the FDF form?
0
Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

 
LVL 44

Accepted Solution

by:
Karl Heinz Kremer earned 400 total points
ID: 12165496
Not for the same price :-(

http://www.websupergoo.com/abcpdf-1.htm - this seems to be free for now, you just have to link back to their web page.

http://www.asppdf.com/
http://dynamicpdf.com/Products/ (last one in the list)
0
 
LVL 44

Expert Comment

by:Karl Heinz Kremer
ID: 12165525
To create multi-line text fields, you need to enable the multi line feature on the properties dialog for your text field (this is on the "Options" tab). In the FDF file, you need to indicate line breaks with '\n':

this is the first line\nand the second line.
0
 
LVL 8

Assisted Solution

by:RLGSC
RLGSC earned 100 total points
ID: 12169902
Darksbane,

Take a look at PDFLIB.COM, the PDFLIB package allows you to directly create PDF files under program control.

- Bob (aka RLGSC)
0
 
LVL 2

Author Comment

by:Darksbane
ID: 12189635
Going with the ABCPDF, thanks for all the help
0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Update 21-May-2015: I temporarily removed the source code and the code snippets to make major changes to the program. Regards, Joe A recent question here at Experts Exchange piqued my interest, so I decided to provide a thorough solution and publ…
Update 21-May-2015: I temporarily removed the source code to make major changes to the program. Regards, Joe In a previous Experts Exchange article, How To Rename-Move a Batch of PDF Files Based on Contents of the Files (http://www.experts-exchan…
In this video, we show how to convert an image-only PDF file into a PDF Searchable Image file, that is, a file with both the image (typically from scanning) and text, which is created in an automated fashion with Optical Character Recognition (OCR) …
In this sixth video of the Xpdf series, we discuss and demonstrate the PDFtoPNG utility, which converts a multi-page PDF file to separate color, grayscale, or monochrome PNG files, creating one PNG file for each page in the PDF. It does this via a c…

774 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question