i'm trying to write an apex class that checks a chekbox, on a custom object when a specific Date is less than 30 days from todays date. The class is supposed to run once a week to constantly check for Records that are supposed to be updated. I have absolutely no knowledge in Apex and my code is made up from various snippeds that I found in other Threads. I think I almost got it, but it keeps showing this error message: Method does not exist or incorrect signature: void DateCheck() from the type CustomersDateCheck.
Can somebody help me out here?
global class CustomersDateCheck implements Schedulable {
global void execute(SchedulableContext sc) {
DateCheck();}
public static void DateCheck(Customers__c[] objects){
for(Customers__c obj: objects){
if(obj.DateField > Date.today()){
continue;
}
else{
obj.FlowUpdateHelper__c = true;
}
}
}
}
Thanks in advance!