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
Paul.FoxPaul.Fox 

Eclipse - Error saving Trigger - Did not find ApexClass component for 'timecardcontroller'

I have a custom object Time_Card__c. I'm trying to create a trigger that will fill in the pay rate based on some criteria.

 

I commented out everything in the trigger except for this and it still won't save:

 

 

trigger Trigger_TimeCard_FindPay on Time_Card__c (before insert, before update) { for(Time_Card__c tc : Trigger.new){ tc.Pay__c = 5; } }

 

 The Error Log says "Did not find ApexClass component for 'timecardcontroller'".

 

I have an Apex Class called timecardcontroller which is used for a Visualforce page which lets people update the Time Cards, but I have no idea what this has to do with this trigger.

 

If I comment out the line that says tc.Pay__c = 5; then it saves correctly.

 

Any ideas on how to fix this?

 

ahab1372ahab1372

are you using the same variable name "tc" in the class?

 

Just a thought ...