Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • EspaƱol
      • FranƧais
      • PortuguĆŖs
  • ę—„ęœ¬čŖžć‚³ćƒŸćƒ„ćƒ‹ćƒ†ć‚£
  • ķ•œźµ­ ģ»¤ė®¤ė‹ˆķ‹°
0

Adobe Acrobat Form > Visual Percentage Calculator with Feedback

Explorer ,
Apr 09, 2023 Apr 09, 2023

I will design a form in Adobe Indesign and open it into Adobe Acrobat to add interactive elements. The idea of the form is to gauge user response to a statement. The user needs to select one of three options valued at 0%, 50% and 100%. Depending on what is chosen, the form will display a visual representation in red= 0%, yellow = 50% or green = 100%, together with appropriate suggestion/feedback (please see attached). Whilst I am familiar with Indesign, I am a complete beginner when it comes to Adobe Acrobat. Hopefully someone from the clever Adobe Support Community can help in layman’s terms/explanation. Providing an example would also be extremely helpful/useful - many many thanks

TOPICS
Create PDFs , How to , JavaScript , PDF forms
1.3K
Translate
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
Enthusiast ,
Apr 09, 2023 Apr 09, 2023

Possible, but no easy task.

 

Translate
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
Explorer ,
Apr 09, 2023 Apr 09, 2023

Thank you for your response. What if form was simplified? User selects one of three options valued at 0%, 50% and 100%. Depending on what is chosen, the form will display a visual representation in red= 0%, yellow = 50% or green = 100% (NO FEEDBACK) - see attached

Translate
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
Explorer ,
Apr 09, 2023 Apr 09, 2023

Ultimately, I think the form will need a script of some kind to display a progress bar to show 0% (red), 50% (yellow) or 100% (green) as chosen by user. Your help would be greatly appreciated! Thanks!

Translate
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 ,
Apr 09, 2023 Apr 09, 2023

You need to use a script to change the fill color (and text color, based on your screenshot) of the fields, based on the user's input. It's not too complicated to implement.

You can use something like this as the custom calculation script of the target field (let's say the field the user enters input into is called "Score1"):

 

var score = Number(this.getField("Score1").valueAsString);
if (score==0) {
	event.target.textColor = color.red;
	event.target.strokeColor = color.red;
	event.target.fillColor = color.white;
} else if (score==50) {
	event.target.textColor = color.ltGray;
	event.target.strokeColor = color.ltGray;
	event.target.fillColor = color.yellow;
} else if (score==100) {
	event.target.textColor = color.white;
	event.target.strokeColor = color.green;
	event.target.fillColor = color.green;
}
event.value = score + "%";

 

Translate
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
Enthusiast ,
Apr 09, 2023 Apr 09, 2023

For 50% it would require two fields to show as on photo.

Translate
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
Explorer ,
Apr 09, 2023 Apr 09, 2023
LATEST

Many thanks for your reply. Am unsure how to test your efforts because: I am unfamiliar with scripting and I am not sure where to place/how to apply script. Could you provide an example please - thanks again

Translate
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