Skip to main content
Participant
August 24, 2023
Answered

Converting a percentage to a grade Adobe Acrobat Pro

  • August 24, 2023
  • 2 replies
  • 751 views

Hi, im a new user and am in the process of creating a simple assessment sheet for an instructor to grade a student.

I have created easy 'Radio Button' rows which allows the instructor to grade student actions from 0-5 (0=didnt not attempt, 1=required major prompting........5=confindent etc).

These scores are then tallied to a 'total' text box which allows me to use the 'sum' option in the calculate tab to get a total.

This is then processed into another 'percentage' text box which converts the total to a percentage.

 

What im now struggling with is how to convert this percentgae to a grade similar to that of a exel spreadsheet ie  =IF(B2>=96%,"Excellent",IF(B2>=91%,"Good",IF(B2>=85%,"Satisfactory",IF(B2>=80%,"Basic",IF(B2>=0%,"Fail")))))

 

Any assistance is greatly appresirated.

This topic has been closed for replies.
Correct answer Nesa Nurani

Use this as 'Custom calculation script' of field where you want to show grade and in script change "Percentage" to your actual name of percentage field. The way it was done in Excel, it will show 'Fail' even when all fields are empty.

var B2 = Number(this.getField("Percentage").valueAsString);
var result;

if(B2 >= 0 && B2 < 0.8){
 result = "Fail";} 
else if(B2 >= 0.8 && B2 < 0.85){
 result = "Basic";} 
else if(B2 >= 0.85 && B2 < 0.91){
 result = "Satisfactory";} 
else if(B2 >= 0.91 && B2 < 0.96){
 result = "Good";} 
else if(B2 >= 0.96 && B2 <= 1){
 result = "Excellent";}

event.value = result;

 

2 replies

Nesa Nurani
Community Expert
Nesa NuraniCommunity ExpertCorrect answer
Community Expert
August 24, 2023

Use this as 'Custom calculation script' of field where you want to show grade and in script change "Percentage" to your actual name of percentage field. The way it was done in Excel, it will show 'Fail' even when all fields are empty.

var B2 = Number(this.getField("Percentage").valueAsString);
var result;

if(B2 >= 0 && B2 < 0.8){
 result = "Fail";} 
else if(B2 >= 0.8 && B2 < 0.85){
 result = "Basic";} 
else if(B2 >= 0.85 && B2 < 0.91){
 result = "Satisfactory";} 
else if(B2 >= 0.91 && B2 < 0.96){
 result = "Good";} 
else if(B2 >= 0.96 && B2 <= 1){
 result = "Excellent";}

event.value = result;

 

Participant
August 24, 2023

Excellent, it works!!!!

Thank you sooooo much!

 

kglad
Community Expert
Community Expert
August 24, 2023

<moved from enterprise and teams >