Tips & Tricks

Import Images into Field with JavaScript

September 16, 2002


Acrobat 5.0 enables you to copy and paste data between PDF files. However, there may be times when you wish to enable interactive elements such as importing images in a PDF file. A good example might be an insurance claims form where photographic images can assist claims adjustment appraisals.

You can set up a button to import an image in a form field with a simple JavaScript routine. To do so, create a form field and select Button for the field type. In the Add an Action dialog box select JavaScript from the Type pull down menu.

In the JavaScript Edit dialog box enter the following line of code:; 

When the user clicks on the button a dialog box will appear enabling navigation to find an image to import.You can secure the form and prevent users from changing fields, yet still enable them to import images.


Images can be imported from the files saved in all formats compatible with the Open As Adobe PDF menu command.

Then using a Digital Camera, you can import directly from the camera or a flash card with a compatible TWIAN driver.

PDF In-Depth Free Product Trials Ubiquitous PDF

Debenu Quick PDF Library

Get products to market faster with this amazing PDF developer SDK. Over 900 functions and an equally...

Download free demo

Five visions of a PDF Day

In the world of PDFs or as we like to say Planet (of) PDF, a year isn't a real PDF year without an intense few days of industry knowledge sharing.

May 15, 2018
Platinum Sponsor

Search Planet PDF
more searching options...
Planet PDF Newsletter
Most Popular Articles
Featured Product

Debenu PDF Aerialist

The ultimate plug-in for Adobe Acrobat. Advanced splitting, merging, stamping, bookmarking, and link control. Take Acrobat to the next level.


Adding a PDF Stamp Comment

OK, so you want to stamp your document. Maybe you need to give reviewers some advice about the document's status or sensitivity. This tip from author Ted Padova demonstrates how to add stamps with the Stamp Tool along with related comments.