PDF application not working properly in web browsers

New Here ,
Apr 14, 2021 Apr 14, 2021

Copy link to clipboard

Copied

Hi!
I am working on a PDF application with fillable forms. There's a payment information section on it's last page that looks like this:
1.png

I wrote JS code on radio button 'mouse up' event so when the user chooses Credit Card option, the whole group of ACH fields are being hidden, and the Credit Card fields become visible. It works perfectly well when the application is opened in Adobe Acrobat, but when I open it in web browsers (I tried Chrome, Opera and Edge with the same result) something strange happens. It seems to me that the fields interfere because of laying on each other. Changing of display property works fine, but when I choose the Credit Card option, its fields are not editale unless I click somewhere on the screen to set the focus off any field. Then I can click on the field and it works. To use the next field, I need to click somewhere again, and so on. After I do that to the fields, they work well without setting focus off.
It's my main problem, and I created a test file illustrating it, it's attached below.

 

However, I've tried to get around the problem and simply move hidden fields to a 'safe' place where they wouldn't interfere with the visible ones by changing their 'rect' property. It also works fine in Acrobat, but it seems that in browsers access to a single radio button of a group using code

this.getField("Group1.0")

 also doesn't work (in fact, it returns 'undefined').

I can't think of what else to do to make the app work in browser properly. Help me please!

P. S.: it also seems pretty strange to me that I wasn't able to find any similar issues in the Community. But maybe I missed something 🙂

TOPICS
Create PDFs, JavaScript, PDF forms

Views

160

Likes

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
New Here ,
Apr 14, 2021 Apr 14, 2021

Copy link to clipboard

Copied

Forgot to say that the second problem is also illustrated in the test file. It is 🙂

Likes

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
Adobe Community Professional ,
Apr 14, 2021 Apr 14, 2021

Copy link to clipboard

Copied

This browers uses their own PDF viewers.

Likes

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
New Here ,
Apr 14, 2021 Apr 14, 2021

Copy link to clipboard

Copied

I understand this, but maybe there is some way to get the app working in browser PDF viewers? I wasn't able to find any documentation about them

Likes

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
Adobe Community Professional ,
Apr 14, 2021 Apr 14, 2021

Copy link to clipboard

Copied

Ask the support of the browsers.

Likes

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
New Here ,
Apr 15, 2021 Apr 15, 2021

Copy link to clipboard

Copied

Thank you for the answers! I'll ask the support 🙂

Likes

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
Adobe Community Professional ,
Apr 14, 2021 Apr 14, 2021

Copy link to clipboard

Copied

Browsers don't support Acrobat JavaScript. You will not be able to get this to work.

Likes

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
New Here ,
Apr 15, 2021 Apr 15, 2021

Copy link to clipboard

Copied

LATEST

Thank you for answering!
That seems pretty weird to me though. I mean, a lot of people open PDFs in browsers, why don't they support such important things 😞

Likes

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