These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

.i want to export the data from pdf as RTF using script

Registered: May 18 2009
Posts: 12


1.i want to export the data from pdf as RTF using script.

2. i want to export the data of one particular field(say data of textfield1) as RTF using acrobat script.

how can we do it ? if any body has any idea or solution .please share with me.


My Product Information:
Acrobat Pro Extended 9.1.3, Windows
Registered: Feb 15 2006
Posts: 4411
When exporting data Acrobat will only include the raw text data, All formatting is lost. So if you want to preserver the formating you'll need to save it explicitly with a scirpt.

How this is done depends on the forms technology you're using and what it is that you want to do. For example, in an AcroForm Rich text is implimented with a series of Span objects, where each span has properties such as the font type, size, and color. The spans are accessed through the "field.richValue" property and can the converted to XML text with the "util.spansToXML()" function.

If this is a LiveCycle form then the RichText is formatted in a different way, it's already XML. RTF is really a very generic term. "RTF files" are different from RTF used in form fields.
If you need it in a different RTF format you'll probably have to write the code to convert it. However, depending on the enviroment this is operating in and what exactly you want to do there might be some other options.

Thom Parker
The source for PDF Scripting Info

The Acrobat JavaScript Reference, Use it Early and Often

Then most important JavaScript Development tool in Acrobat
[url=][b]The Console Window (Video tutorial)[/b][/url]
[url=][b]The Console Window(article)[/b][/url]

Thom Parker
The source for PDF Scripting Info
Very Important - How to Debug Your Script