You need to sign in to do that
Don't have an account?

Field is not writeable: CronTrigger
Hello,
I'm trying to do the upgrade of the PreviousFireTime field into CronTrigger, but I try an error:
Error: Compile Error: Field is not writeable: CronTrigger.CronExpression
LINE: ct.PreviousFireTime = VariablePreviousExec;
Why?
Thank you!!!
I'm trying to do the upgrade of the PreviousFireTime field into CronTrigger, but I try an error:
Error: Compile Error: Field is not writeable: CronTrigger.CronExpression
LINE: ct.PreviousFireTime = VariablePreviousExec;
Why?
.... CronTrigger[] acctsList = [SELECT PreviousFireTime FROM CronTrigger where CronJobDetail.Name =: VariableName ]; for (CronTrigger ct : acctsList) { ct.PreviousFireTime = VariablePreviousExec; } try { upsert acctsList; } catch (DmlException e) { // code... } .....
Thank you!!!
All Answers