Simulation syntax error

In reply to pinnuk:

This looks OK.
Could you please post some example simplified code to validate the structural issue you are facing.