ibex
09-03-2010, 10:56 PM
Firstly I'm not a VBA programmer so this may be really obvious but I can't find the answer myself.
I have a very simple macro in Outlook 2007 that is called when the "send" button is pressed
Private Sub Application_ItemSend(...
This macro brings up the ShowCategoriesDialog so that I can assign a category (1 or more) to each outgoing email. This works fine.
' Pick the category
Set item = Outlook.Application.ActiveExplorer.Selection.item(1)
item.ShowCategoriesDialog
What I would like to do is take different actions depending on whether the "OK" or the "Cancel" button is clicked to exit the ShowCategoriesDialog. I don't know how to detect which button was presssed or even know if the button result is available once the ShowCatagoriesDialog has returned.
All help gratefully accepted.
I have a very simple macro in Outlook 2007 that is called when the "send" button is pressed
Private Sub Application_ItemSend(...
This macro brings up the ShowCategoriesDialog so that I can assign a category (1 or more) to each outgoing email. This works fine.
' Pick the category
Set item = Outlook.Application.ActiveExplorer.Selection.item(1)
item.ShowCategoriesDialog
What I would like to do is take different actions depending on whether the "OK" or the "Cancel" button is clicked to exit the ShowCategoriesDialog. I don't know how to detect which button was presssed or even know if the button result is available once the ShowCatagoriesDialog has returned.
All help gratefully accepted.