[Studio] timer event attached to an activity is not triggered


I have a (reusable) subprocess within the the process. This subprocess has attached timer event which is configured in expression by writing

  1. var iDuration= Global.getActivitySLAGlob(Me,sla,Me.Task.Name);

    Global.Trace(Me,sRuleName,"tIMERDuration " + iDuration);

    Me.TimerEventDuration = iDuration;

As you can see from the code I know for certain that correct value is passed to

  1. Me.TimerEventDuration

At the same time I set for the same activity also Task Duration which is basically the same code:

  1. var iDuration= Global.getActivitySLAGlob(Me,sla,Me.Task.Name);

    Global.Trace(Me,sRuleName,"Duration " + iDuration);

    Me.Duration = iDuration;

The order of the expression is:

1. Set timer duration

2. Set task duration.

Order of the task doesn't seem to have any impact.

Working time schema is set to default 24h.

Both values are equal

The question is what my the reason that the activity doesn't to proceed further. Instead of that the task switches to expired (is red)

Many thanks for any ideas suggestions