To get that, use a variable to store the collision. Then, use another variable to store the previous state of the collision:
Now, you can compare coll to oldcoll, and if they are different you can respond to it, ie:
oldcoll = coll coll = (EntityCollided (sphere, type_cube) <> 0)
Now, you can compare coll to oldcoll, and if they are different you can respond to it, ie:
If coll and (not oldcoll) Then ..