Represents a task (an assigned, delegated, or self-imposed task to be performed within a specified time frame) in a Tasks folder.
Using The TaskItem Object
Use the CreateItem method to create a TaskItem object that represents a new task.
The following Visual Basic for Applications (VBA) example returns a new task.
Set myOlApp = CreateObject("Outlook.Application") Set myItem = myOlApp.CreateItem(olTaskItem)
The following sample shows how to create a task using Microsoft Visual Basic Scripting Edition (VBScript).
Set myItem = Application.CreateItem(3)
Use Items (index), where index is the index number of a task or a value used to match the default property of a task, to return a single TaskItem object from a Tasks folder.
If a program tries to reference any type of recipient information by using the Outlook object model, a dialog box is displayed that asks you to confirm access to this information. You can allow access to the Address Book or recipient information for up to ten minutes after you receive the dialog box. This allows features, such as mobile device synchronization, to be completed.
You receive the confirmation dialog box when a solution tries to programmatically access the following properties of the TaskItem object: