• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
1

Android buttons actions saved PDF, javascript

Community Beginner ,
Dec 24, 2019 Dec 24, 2019

Copy link to clipboard

Copied

Good afternoon,

 

I have the necessity to create a fillable PDF document which have to be sent to an Android device. This have also to be able to filled it out and save it (with a specific name) in a selectable folder on this device. I tried to create some buttons and assign to them fixed actions, but these work only on the Win PC, is it possible to insert a javascript in the buttons to allow the Android device saving the document with a name? On the Android device I use Adobe Reader downloaded from the Play store.

Thanks to help me out here.

Views

2.4K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 26, 2019 Dec 26, 2019

Copy link to clipboard

Copied

Hi,

 

In a computer with Adobe Acrobat DC, open your form and select the Prepare Form tool.

 

You can add a button with an action such as "Save As". Then save it and upload the form in your mobile device.

 

I personally haven't tested the Save As action button script but I do have a form with a Reset Button action that works in my Reader mobile app.

 

You should be able to use this button,.

 

However, It is my understanding that such feature is not necessarily needed in your case because you can select in your mobile device your PDFs documents default saving location directly from the Reader Mobile app.

 

When this Preferences setting is configured to locally save PDFs  to a location of your choice in that mobile device, any changes made to your PDF document are automatically saved and the file will remain accessible there in that folder unless you decide later to copy it somewhere else.

 

If what you're trying to achieve is to click on a button that will instruct the mobile app to automatically save  PDF document to a specific location in a mobile device,  that is not possible and not supported.

 

What you described in your post only works at a  desktop level of computing where applying a folder level script  to your form is also  exclusively dependent of the directory structure of the  operating system that the PDF application is locally installed and  executing from.

 

So for the mobile app you can set the default saving location, for example.

 

PDFs documents that you open and edit with the Reader Mobile App will  be saved automatically with changes to the default location you've selected in the Reader Mobile App Preferences.

 

You can manually configure this setting as shown in the following slide:

 

Screenshot_20191226-043255.jpg

 

No manual intervention is needed when you use your files locally in your device, unless you want to rename the file shown in the following slides:

 

 Click on the three dots for More Options, right margin of the filename and a menu will open from the bottom up offering the rename option

 

Screenshot_20191226-044856.jpg

Select rename and a prompt will allow you to retype the filename

Screenshot_20191226-045132.jpg

 

As you can see, with the mobile app this is a simple two step procedure.

 

However, you have to test and verify how adding a button script with a Save As action to your form  will behave in the mobile devices where it will be used (both Android or iOS devices).

 

For example, if it actually works, it is very probable that the user will be prompted to save the file to the document cloud, shown in the next slide:

Screenshot_20191226-043820.jpg

 

If this would be your case, It will always require manual intervention from the user on how such file  needs to be saved to or moved to.

 

If the file is saved to the document cloud, a folder needs to be created  first in order to be able to move that file later to another cloud folder:

 

Screenshot_20191226-052044.jpg

 

 

Screenshot_20191226-052054.jpg

 

 

Screenshot_20191226-052140.jpg

So again, these are options that only work with manual intervention from the user. 

 

In my personal opinion, however, I think you're better off if you add to your form a Print action button script.

 

The reason why, is because it will  open up the print option in your mobile device and will offer the user the option to print to PDF.

 

This is by far the easiest way to have that PDF saved locally to a mobile device without going through the hassles illustrated above.

 

When and if you chose to test the print action button with your pdf form, the user will be prompted instead with a similar screen:

 

Screenshot_20191226-051743.jpg

 

All the user needs to do is select from the pulldown menu "Save as PDF" and then click on the yellow icon to download/save to the mobile device  as PDF .

 

Then next screen that will popup next will allow the user  to select  then MyDocuments  folders or any other local folder in the SD Card of that mobile device or to the internal device storgae folders

 

Screenshot_20191226-051803.jpg

 

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Dec 27, 2019 Dec 27, 2019

Copy link to clipboard

Copied

Hi,

thank you for the reply.

I tried to set the buttons that allow me to run an item from the menu (save as, print, reset form) and save the file with the advanced functions for adobe reader. These buttons work on windows, but they don't work on android.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 27, 2019 Dec 27, 2019

Copy link to clipboard

Copied

Acrobat Reader for Android has not this menu entries.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Dec 27, 2019 Dec 27, 2019

Copy link to clipboard

Copied

The PDF imposed by PC using Adobe Acrobat Pro, the reader I use it on my mobile devices, but they do not start any action by pressing the button

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 27, 2019 Dec 27, 2019

Copy link to clipboard

Copied

Correct.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 27, 2019 Dec 27, 2019

Copy link to clipboard

Copied

I was not talking about Adobe Reader.

 

Your question was about how to add a javascript to a button.

 

At the beginning of my answer I clearly said, "In a computer with Adobe Acrobat DC, open your form and select the Prepare Form tool".

 

Adobe Acrobat is the PDF editor  program that will allow you to create PDF documents with additional objects and elements to aid the users of the form with workflow.

 

When you edit a PDF document with Acrobat (not Reader) you will be able to open and use that PDF document in other platforms, to include mobile devices.

 

The button that I was referring to is not a menu item, but an object that you can add inside of the actual PDF document, so when the users are interacting with that form they can click on it to manually execute a specific action such as Print, Save As, Reset.

 

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Dec 30, 2019 Dec 30, 2019

Copy link to clipboard

Copied

Thank you for the reply. I followed your advice , adding an action to a button. In the following images you can see what I've done: 

Immagine.png

Immagine1.png

Immagine2.png

Immagine3.png

At the end, I saved the document with the advanced functions for Adobe Reader.

The result was that this button works on Windows, but don't work on my mobile device with Android.

How could I set this function also for my mobile devices?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 30, 2019 Dec 30, 2019

Copy link to clipboard

Copied

Acrobat Reader for mobile devices doesn't have this menu entries.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 30, 2019 Dec 30, 2019

Copy link to clipboard

Copied

LATEST

Hi,

 

What do you mean by save with the advanced options for Reader?

 

Did you use Save As Other--->>More Tools --->> Reader Extended?

 

Also before you Save As you also need to reduce the file size or perform optimization for mobile devices.

 

Can you share an example of your file? 

 

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines