PDF Editing Issues

Calculate and Round Up Overtime Pay in an Acrobat Form

Rana GarciaRana Garcia Nov 19, 2026 869 views

Question details

Calculate an overtime pay rate in a fillable PDF by multiplying the base rate by 1.5 and rounding the result up.

Calculate and Round Up Overtime Pay in an Acrobat Form
Product
Adobe Acrobat
Device & OS
not provided
Scenario
A form author wants an overtime pay rate field to calculate automatically from a base pay rate field.
Observed behavior
The overtime field should display the calculated rate rounded up to the next whole dollar.
Before you start

Open the fillable PDF in a version of Adobe Acrobat that can edit form fields, and check the exact names of the base rate and overtime rate fields. The example below uses BasePayRate and OT_PayRate and expects a numeric base rate without currency symbols or thousands separators.

Solution 1Recommended

Add a custom calculation script to the overtime rate field

Use Acrobat's form field calculation settings to multiply the base rate by 1.5 and round up to a whole dollar.

1
Open the form editor

In Acrobat, open the PDF and choose Prepare a form from the tools. Locate the BasePayRate and OT_PayRate fields.

2
Open the calculation settings

Double-click OT_PayRate to open its properties. Select the Calculate tab, choose Custom calculation script, and click Edit.

3
Enter the script

Paste this script, replacing BasePayRate with the exact source field name if needed: var raw = this.getField("BasePayRate").valueAsString; if (raw === "" || !isFinite(Number(raw))) { event.value = ""; } else { event.value = Math.ceil(Number(raw) * 1.5); }

4
Set the display format

Click OK to save the script. In the field's Format tab, select Number and choose the desired decimal places, such as 2 for a dollar-style display.

5
Test the form

Close the field properties and use Preview to enter a base rate. For example, 15.25 should produce 23, displayed as 23.00 if two decimal places are selected.

Add a custom calculation script to the overtime rate field
Rounding and display are different: Math.ceil rounds the calculated rate up to a whole dollar. Setting two decimal places only changes its display; it does not round the rate up to the next cent.
Free Microsoft Office alternative

Work with PDF forms and pay-rate spreadsheets in WPS Office

WPS Office is a free, lightweight alternative for working with PDFs and office documents in a familiar interface. Its Microsoft Office format support makes it easier to move existing documents and spreadsheets into your workflow. Use Adobe Acrobat for the custom form calculation described above.

Open PDF forms alongside your other work documentsWork with Microsoft Word DOCX and Excel XLSX filesUse a familiar interface for documents and spreadsheetsMove existing Office files into a lightweight workspace
QA img-9

Frequently Asked Questions

Why does the overtime rate show 23.00 instead of 22.88?

The script uses Math.ceil to round 15.25 multiplied by 1.5 up to the next whole dollar. The Format tab controls the displayed decimal places, so two decimal places display the result as 23.00.

How can I round up to the next cent instead?

In the OT_PayRate field's Calculate tab, change the calculation expression to Math.ceil(Number(raw) * 1.5 * 100) / 100, and set two decimal places on the Format tab. Test representative rates because floating-point arithmetic can affect values near cent boundaries.

What should I check if the overtime field stays blank?

In Prepare a form, verify that the source field is named BasePayRate or update the name in the script. Enter a plain numeric value without a currency symbol or thousands separator, and confirm the script is saved under OT_PayRate's Calculate tab.

Can I add the calculation script in Acrobat Reader?

Adding or editing form field calculations requires an Acrobat version with form-editing tools. Open the PDF in Acrobat and look for Prepare a form to edit the field properties.