added code for getting the details of the activity for viewing purposes