I am wanting to verify the TOTAL and Amount fields are equal only if the Type of Payment is "Right of Way" (.paytype). The TOTAL field only shows if "Right of Way" is selected. I found some helpful JS on LF Answers, but since I don't have anything checking to see if the Type of Payment is Right of Way it runs even when the TOTAL field is hidden causing the submit button to disable. Could someone please help me fix the JS below to only run when Type of Payment (.paytype) equals "Right of Way"?
JavaScript:
Form Preview: