Normally during hook_civicrm_postProcess, you can get the id of the just created activity from $form->_activityId
. For activities of type Email, I can't see how to get the activity id. Am I just missing something simple?
I don't think I can use hook_civicrm_post instead because I want to use information in the form that isn't in the activity object, but the form info isn't available in hook_civicrm_post.