Jump to content

Form field to add an image?


rob durose
 Share

Recommended Posts

rob durose

Hi.

I've had a look and didn't find any info on this, i am guessing it is not possible but thought i'd ask.

Is there any way to create a form field that allows people to click and add their own image? So like a text field but instead of adding text they can add an image from a folder on thier machine.

 

Regards and thanks.

Link to comment
Share on other sites

  • Official Nitronaut
Reymund G.

Hi @rob durose

Thank you for reaching out to us through our Community Forums!

There's no specific form field in Nitro Pro that is designed to add/insert an image. You can use the Button form then add Javascript action to import an image. 

Here are the steps:

1. Go to Forms tab and place a button in the document. 
2. Click 'Select Fields' then right click the button form and select Properties
3. Under Options tab, set the Layout to 'Icon only'.
4. Under Actions tab, set the following:

a. Select Trigger: Mouse Up
b. Select Action: Run a JavaScript

5. Click Add to List button. This will open the JavaScript Editor. Enter the script below:

event.target.buttonImportIcon();

6. Click Ok then close the Button Properties. 

You may need to adjust the size of the button, depending on the size of the image that will be placed on it. Also, when you click the button, you will need to set the file selection from PDF files to Image files so you could see and select the image that you need to import/insert.

Kind regards,

Edited by Reymund G.
Link to comment
Share on other sites

  • 8 months later...
Sultan Fikri

Thanks Reymund

when i use Computer, it work fine, but when i use in Android Phone, Select Image doesn't work

what should i change in this JavaScript???

event.target.buttonImportIcon();

 

Link to comment
Share on other sites

  • Official Nitronaut
Reymund G.

Hi @Sultan Fikri

Thank you for reaching out to us through our Community Forums!

Android OS may have a different function when executing JavaScripts and my apologies if our support for defining custom scripts including JavaScript are limited. 

Kind regards,

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.