You'll need a counter variable, and a state variable (Boolean instance variable would be good).
On collision with object and statevariable is false, set statevariable to true, and set countervariable to 0.
The next event should have the conditions system else, on collision with object, and statevariable is true, then set statevariable to false.
In the last event event, if state variable is true, set counterrvariable to countervariable+dt.
The time elapsed between your collisions will be available as countervariable.