In your secondary activity, under Process_Globals, create a variable like:
Dim Started as Boolean
Right before you call Activity.Finish in your secondary activity do this:
Started = True
Then in your main activity, under Activity_Resume do this:
If secondactivity.Started = True Then
do whatever you want here
secondactivity.Started = False
End If