Ive been using the following example to complete milestones on Case Close which works fine when editing an existing Case.


However, this doesn't work when the rep creates a case and immediately marks it as closed as the Milestones do do exist at that point. I've tried using @future to execute the milestone logic after the case and milestones have been created, however, i then hit this error:

"You can’t change the completion date on a milestone that’s already exited an entitlement process.: Completion Date: [CompletionDate]”

Any suggestions on how to complete milestones when a Case is closed on insert?

  • Better do not create milestones when case is created with closed status Apr 15, 2018 at 21:36

1 Answer 1


Edit the entitlement process to have an exit criteria other than "on close", that way the case won't exit the entitlement process, you can close the milestone and then exit the process.

I have the same problem but a slightly different root cause.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.