Pep Grifell wrote:
> hi there,
>  
> I have a preprinted medical recipe and I need to fill some fields in it 
> from my web app.
>  
> One of the ideas I had is to scan the recipe in a PDF, and then fill the 
> gaps (by this way, I will not have to print the recipe and spend paper 
> in vain).

Why scan it?
Don't you have the original document in digital format?

Suppose you don't, then you have to scan the document,
and create a PDF with the raster image that was obtained.

Then you have to add form fields to that PDF.
You can do this, for instance with Adobe Acrobat.
Make sure that you add AcroForm fields (Text field annotations).
Please don't create an XFA form.

> Once I will have all the gaps filled and the text placed correclty,

You're one step too quickly: you shouldn't fill the gaps!
First you have to define the fillable areas.
Then you can use iText to fill the gaps.

> I 
> will generate a PDF with the text (withou the preprinted recipe)

One way to do this, is to put the background in an "optional
content group". "Optional" in the sense that it is visible
when viewed on screen, but not visible when printed on paper.

> and I 
> will send it to the printer, where I will have the preprinted paper.

That's what the "optional content" is about ;-)

> This can be done with iText ? 

Of course, you can do the filling and the optional content stuff
with iText, but you'll have to define the coordinates of the gaps
manually first using another tool. If you don't have any other tool,
you can measure the coordinates manually (using a ruler) and then
use the coordinates you've obtained in iText.
-- 
This answer is provided by 1T3XT BVBA
http://www.1t3xt.com/ - http://www.1t3xt.info

------------------------------------------------------------------------------
This SF.net email is sponsored by Sprint
What will you do first with EVO, the first 4G phone?
Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions

Buy the iText book: http://www.itextpdf.com/book/
Check the site with examples before you ask questions: 
http://www.1t3xt.info/examples/
You can also search the keywords list: http://1t3xt.info/tutorials/keywords/

Reply via email to