TaskItem.ShowCategoriesDialog Method (Outlook)


Contribute to this content

Use GitHub to suggest and submit changes. See our guidelines for contributing to VBA documentation.

Displays the Show Categories dialog box, which allows you to select categories that correspond to the subject of the item.

expression .ShowCategoriesDialog

expression A variable that represents a TaskItem object.

The following Microsoft Visual Basic for Applications (VBA) example creates a new task item, displays the item on the screen, and opens up the Show Categories dialog box.

Sub TaskItem() 
 'Creates a task item to access ShowCategoriesDialog 
 Dim olmyTaskItem As Outlook.TaskItem 
 'Create task item 
 Set olmyTaskItem = Application.CreateItem(olTaskItem) 
 olmyTaskItem.Subject = "Sales Reports" 
 'Display the item 
 'Display the Show categories dialog 
End Sub 

© 2015 Microsoft