ExchangeService.CreateItems method

Creates multiple items in a single Exchange Web Services (EWS) call.

Namespace:  Microsoft.Exchange.WebServices.Data
Assembly:  Microsoft.Exchange.WebServices (in Microsoft.Exchange.WebServices.dll)

public ServiceResponseCollection<ServiceResponse> CreateItems(
	IEnumerable<Item> items,
	FolderId parentFolderId,
	Nullable<MessageDisposition> messageDisposition,
	Nullable<SendInvitationsMode> sendInvitationsMode


Type: System.Collections.Generic.IEnumerable<Item>

The items to be created.

Type: Microsoft.Exchange.WebServices.Data.FolderId

The ID of the folder in which the newly created items are to be placed. If this parameter is a null reference (Nothing in Visual Basic), items are created in their default folders.

Type: System.Nullable<MessageDisposition>

One of the enumeration values that specifies the disposition mode for EmailMessage objects. This parameter is required for items that contain at least one EmailMessage instance.

Type: System.Nullable<SendInvitationsMode>

One of the enumeration values that specifies whether and how invitations should be sent for items of type Appointment. This parameter is required for items that contain at least one Appointment instance.

Return value

Type: Microsoft.Exchange.WebServices.Data.ServiceResponseCollection<ServiceResponse>
A collection of creation results for each of the specified items.

The CreateItems(IEnumerable<Item>, FolderId, Nullable<MessageDisposition>, Nullable<SendInvitationsMode>) method supports the EmailMessage, Appointment, Contact, PostItem, Task, and Item types. This method does not support items that have unsaved attachments.