How to mark an activity as completed?