similar look documents problem

New Here ,
Apr 03, 2018

Copy link to clipboard

Copied

Hello everyone , I'm new with JS in PDF. I try to find answer for my question, byt cant find it anyware. I create 3D inteactive document based on forms and buttons and it works but dont look everywhere the same. For example: sometimes PDF Reader have different Edit>Preferences>Forms> Hightlight Color. I try to write small script to change this Preference to have the same value. Any body open document have the same setupPreferences like : Capture.PNG.

It is possible? Thanks for answer.

Adobe Community Professional
Correct answer by Joel_Geraci | Adobe Community Professional

You can turn off field highlighting with the following. Setting it to true will turn it back on.

app.runtimeHighlight = false

You can control the highlight color using the following. See the Color Object to change what color gets used.

app.runtimeHighlightColor = color.red;

This doesn't change the user preference, it just sets the properties for that document.

TOPICS
Acrobat SDK and JavaScript, Windows

Views

119

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

similar look documents problem

New Here ,
Apr 03, 2018

Copy link to clipboard

Copied

Hello everyone , I'm new with JS in PDF. I try to find answer for my question, byt cant find it anyware. I create 3D inteactive document based on forms and buttons and it works but dont look everywhere the same. For example: sometimes PDF Reader have different Edit>Preferences>Forms> Hightlight Color. I try to write small script to change this Preference to have the same value. Any body open document have the same setupPreferences like : Capture.PNG.

It is possible? Thanks for answer.

Adobe Community Professional
Correct answer by Joel_Geraci | Adobe Community Professional

You can turn off field highlighting with the following. Setting it to true will turn it back on.

app.runtimeHighlight = false

You can control the highlight color using the following. See the Color Object to change what color gets used.

app.runtimeHighlightColor = color.red;

This doesn't change the user preference, it just sets the properties for that document.

TOPICS
Acrobat SDK and JavaScript, Windows

Views

120

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
Apr 03, 2018 0
Adobe Community Professional ,
Apr 03, 2018

Copy link to clipboard

Copied

You can turn off field highlighting with the following. Setting it to true will turn it back on.

app.runtimeHighlight = false

You can control the highlight color using the following. See the Color Object to change what color gets used.

app.runtimeHighlightColor = color.red;

This doesn't change the user preference, it just sets the properties for that document.

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
Reply
Loading...
Apr 03, 2018 0
Adobe Community Professional ,
Apr 03, 2018

Copy link to clipboard

Copied

This will change the user preference.

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
Reply
Loading...
Apr 03, 2018 1
Adobe Community Professional ,
Apr 04, 2018

Copy link to clipboard

Copied

Oh wow. You'r right. There was a time when it doesn't. The fact that it does has got to be a bug.

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
Reply
Loading...
Apr 04, 2018 0
Adobe Community Professional ,
Apr 04, 2018

Copy link to clipboard

Copied

Why is this a bug? You can change the properties of the app object without a open document.

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
Reply
Loading...
Apr 04, 2018 0
Most Valuable Participant ,
Apr 04, 2018

Copy link to clipboard

Copied

I would also consider it a bug, or at least an improperly implemented feature. A script in a document should not be allowed to change a setting that applies to other files as well, in my opinion. This setting should be file-specific.

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
Reply
Loading...
Apr 04, 2018 0
Adobe Community Professional ,
Apr 04, 2018

Copy link to clipboard

Copied

Then it must be properties of the document, not application.

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
Reply
Loading...
Apr 04, 2018 0
Adobe Community Professional ,
Apr 04, 2018

Copy link to clipboard

Copied

A script in a document should never be able to permanently change application preferences.

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
Reply
Loading...
Apr 04, 2018 0
New Here ,
Apr 04, 2018

Copy link to clipboard

Copied

Thank you very much!

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
Reply
Loading...
Apr 04, 2018 0