JavaScript for Clearing JPEGs out of a Form??? (Adobe Acrobat Pro DC)
I am building a simple form to have employees submit their weekly "Photo Reports" from the field.
I have set up a large button (space large enough for the JPEG) using the following JavaScript: event.target.buttonImportIcon();
When the form is blank, I am able to click on the big gray box (button) to have a prompt appear that says "Select Icon".
From there, I am able to "Browse..." and select a JPEG from my files.
I click "Open" followed by "Okay".
The picture proportionally fills the space that I want the JPEG to be in the form.
This is exactly what I want.
However, once that JPEG is in its location, I cannot delete it.
I can click on it and the "Select Icon" prompt appears; I can select a different photo.
But I cannot easily clear the photo without editing the form.
I want the end-user to be able to clear the pictures in the form the same way that text can be cleared.
I have very very little experience with all of this.
Any direction would be best received in a "step-by-step" format.
Overall Goal:
-- Build a button that clears a single photo
and/or
-- Build a button that clears all the photos that are added to the form.
