function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Gary PayneGary Payne 

Error with DEV401 Apex Trigger

I am working through the Dev401 Implementing Business Processes Exercise Guide 4-5: Create Dynamic Approval Processes, Item 7. The Apex Trigger provided in the downloaded zip file contains an error and will not save. Following is the Trigger:

trigger PositionApprovalTrigger on Position__c (before insert, before update) {
The error received is: "Error: Compile Error: Variable does not exist: PositionApproval at line 2 column 5".

Three custom fields (Approve_1, Approver_2, and Approver_3) are created in the custom object Positions__c, but there is no "PositionApproval" field.  What is needed to correct the Trigger so I can complete this training exercise?  I am not a coder, just an admin trying to become a developer.
PositionApproval is the apex class called in the trigger code. You have to first create a apex class PositionApproval with the static method setPositionApprovers then you have to create/save this trigger code. Check in the zip file do you have any other class file 
Gary PayneGary Payne
Thank You for the quick reply! Creating the Apex Class first was helpful. Gary Payne, CRM Administrator/Information Technology SWBC 9311 San Pedro Ave., Suite 600 San Antonio, TX 78216 888-391-6707 - Toll Free/ Help Desk 210-376-6057 - Direct 714-474-5915 - Mobile 210-468-4135 - Fax [cid:image001.png@01D0575E.271DC870] [Description: Description: Description: Description: facebook-official-28px] [Description: Description: Description: Description: linkedIn-official-28px] [Description: Description: Description: Description: youTube-sm] [Twitter_logo_email] [cid:image007.png@01D0575E.271DC870] Visit our website at