Version Check

Avatar

Avatar
Give Back
Level 1
JLNdev
Level 1

Like

1 like

Total Posts

13 posts

Correct reply

1 solution
Top badges earned
Give Back
Ignite 1
Validate 1
Boost 1
Applaud 5
View profile

Avatar
Give Back
Level 1
JLNdev
Level 1

Like

1 like

Total Posts

13 posts

Correct reply

1 solution
Top badges earned
Give Back
Ignite 1
Validate 1
Boost 1
Applaud 5
View profile
JLNdev
Level 1

18-09-2017

Hi everyone,

Our LCD form does an Adobe Acrobat Reader version check before it opens, using the following JS:


if (parseFloat(app.viewerVersion) < 12)

  {

  xfa.host.messageBox("If you are seeing this message, your version of Adobe Acrobat Reader may be outdated.\n\nFor best user experience, please download the latest version of Adobe Acrobat Reader DC at https://get.adobe.com/reader.", "Adobe Acrobat is outdated", 0, 0);

  }

However, many of our users are going to get annoyed by how often they see this prompt, if they can't or won't update their Reader to the latest version. Is there a way to add a check box to the message box that allows the user to suppress future notices of this kind? Such as "[ ] Do not tell me to update anymore"?

I feel like this might not be possible, since it seems like it would be a program-level change (rather than something that could be remembered for the form, itself), but I figured I'd try asking about it, just in case.

Thanks for taking the time to read my question!

JLN

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Give Back
Level 1
JLNdev
Level 1

Like

1 like

Total Posts

13 posts

Correct reply

1 solution
Top badges earned
Give Back
Ignite 1
Validate 1
Boost 1
Applaud 5
View profile

Avatar
Give Back
Level 1
JLNdev
Level 1

Like

1 like

Total Posts

13 posts

Correct reply

1 solution
Top badges earned
Give Back
Ignite 1
Validate 1
Boost 1
Applaud 5
View profile
JLNdev
Level 1

15-12-2017

Hi Radzmar and MinusZero,

 

I'm dying to try it, but I haven't quite gotten to it yet. I'll definitely post about my success/failure once I do, though!

 

I really appreciate your taking the time to talk me through it--this is extremely helpful.

 

JLN

 

UPDATE: This worked, thanks so much!

if (parseFloat(app.viewerVersion) < 12)

  {

  xfa.host.messageBox("If you are seeing this message, your version of Adobe Acrobat Reader may be outdated.\n\nFor best user experience, please download the latest version of Adobe Acrobat Reader DC at https://get.adobe.com/reader.", "Adobe Acrobat is outdated", 0, 0);

  }

Answers (4)

Answers (4)

Avatar

Avatar
Validate 1
Level 5
dcidev
Level 5

Likes

30 likes

Total Posts

448 posts

Correct reply

77 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 25
Boost 10
View profile

Avatar
Validate 1
Level 5
dcidev
Level 5

Likes

30 likes

Total Posts

448 posts

Correct reply

77 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 25
Boost 10
View profile
dcidev
Level 5

15-12-2017

Object.defineProperty is a big one for our PDFs. Can't extend the Object class with custom methods that are non-enumerable.

Avatar

Avatar
Coach
MVP
radzmar
MVP

Likes

397 likes

Total Posts

2,687 posts

Correct reply

492 solutions
Top badges earned
Coach
Ignite 3
Ignite 1
Validate 1
Give Back 50
View profile

Avatar
Coach
MVP
radzmar
MVP

Likes

397 likes

Total Posts

2,687 posts

Correct reply

492 solutions
Top badges earned
Coach
Ignite 3
Ignite 1
Validate 1
Give Back 50
View profile
radzmar
MVP

24-09-2017

Does this test makes sense? I mean, what feature you're using in your form that requires at least Acrobat (Reader) DC?

Avatar

Avatar
Validate 1
Level 4
mouslander
Level 4

Likes

23 likes

Total Posts

298 posts

Correct reply

27 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 10
Boost 1
View profile

Avatar
Validate 1
Level 4
mouslander
Level 4

Likes

23 likes

Total Posts

298 posts

Correct reply

27 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 10
Boost 1
View profile
mouslander
Level 4

22-09-2017

MinusZero's solution will work IF the user is opening a form they saved. i.e. open it, get the message, accept the message and save the document. On reopen the solution will suppress the message, however if this is a form the user opens, fills out, submits (or emails) and they are done with it, then they will get the message every time a new form is opened. You cannot suppress this kind of message at the application layer. Additionally the question I have is that if you are going to the trouble of telling the user they need the newer version why would you suppress the message anyway? if the recommendation is to use a newer version there must be some reason for this??

Avatar

Avatar
Validate 1
Level 4
MinusZero
Level 4

Likes

30 likes

Total Posts

326 posts

Correct reply

54 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 25
Boost 10
View profile

Avatar
Validate 1
Level 4
MinusZero
Level 4

Likes

30 likes

Total Posts

326 posts

Correct reply

54 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 25
Boost 10
View profile
MinusZero
Level 4

18-09-2017

Hi,

I have tackled something like this before. You can achieve this by using a variable, but since they can be so finicky to use I did it a much simpler way.

What do you have to do?

  • Add a hidden NumericField. Give it the value 1.
  • Add some code into the Form's Doc:Ready event.

form1::docReady - (JavaScript, client)
if(this.resolveNode("NumericField1").rawValue == "1") //checks the value of the NumericField, if it is "1" execute the code.

{
var resetText = app.alert("If you are seeing this message, your version of Adobe Acrobat Reader may be outdated.\n\nFor best user experience, please download the latest version of Adobe Acrobat Reader DC at ....\n\nHide this dialog next time?",2,2, "Adobe Acrobat is Outdated"); //show a checkbox with Yes and No buttons


if(resetText == "4") //4 equals yes
{
this.resolveNode("NumericField1").rawValue = "0"; //if Yes is clicked, change the NumericField value to 0
}
else
if(resetText == "3") //3 equals no
{
this.resolveNode("NumericField1").rawValue = "1"; //if No is clicked, change the NumericField value to 1. This isnt really needed if the value starts at 1, but if you wish to add an event to make it show again, you will want this.
}
}

if(this.resolveNode("NumericField1").rawValue == "0") //If the value of the NumericField is 0, execute this code...which is nothing.
{

}

-------------------------------------------------------------------------

When you save the form, the NumericField's contents are saved with the form so next time it is opened the code will execute and show or not show the dialog based on what was done last time and saved into the form.

If you have a form reset button you might want to reset the NumericField's value back to 1 so the form is fully resetting. Just add it to the click event of the reset button.

In your code, just add a second if statement after the version check code. eg:

if (parseFloat(app.viewerVersion) < 12)

     {

     if(this.resolveNode("NumericField1").rawValue == "1")

          {

          }

     etc etc

     }