[SalesForce] Milestone elapsed / actual elapsed / stopped times are always empty

I have a CompletedCaseMilestone custom object that I use to store the completed milestones for statistical analysis later. Everything is working great, but I came across an issue when I'm also using IsStopped flag on the Case object.

I have a process that sets IsStopped to true if the status is On Hold, and set it to false otherwise. The flag is working – when it is true, the milestones are stopped, when it changes back to false, the milestones continue to count.

The issue is that the StoppedTimeInX, ElapsedTimeInX and ActualElapsedTimeInX fields are always empty. I need those fields in order to calculate the actual time for the milestone to complete without the stopped time.

I've enabled Enable stopped time and actual elapsed time checkbox in the Entitlement Settings section, and added all the fields to the Case Milestone page layout – but still nothing.

How can I get those fields to work?

Update:

I've confirmed in the work bench that the fields in question exist on the CaseMilestone object.

enter image description here

Best Answer

If the milestone is stopped upon using isStopped attribute at Case level then after certain time when it comes back to isStopped=false then automatically those StoppedTimeInX, ElapsedTimeInX and ActualElapsedTimeInX values are not displayed.

Those values only get displayed when Milestone is completed.

Refer this screenshot below from my DE where all the respective values are displaying.

Milestone

Related Topic