Add Method
Add Method
This content is no longer actively maintained. It is provided as is, for anyone who may still be using these technologies, with no warranties or claims of accuracy with regard to the most recent product version or service release.
Adds a new member to the collection.
Applies To
Type Library
Microsoft CDO Workflow Objects for Microsoft Exchange
DLL Implemented In
CDOWF.DLL
Syntax
[Visual Basic]Sub Add
(
bsName As String,
Type As MemberType
)
[C++]HRESULT Add ( BSTR bsName, MemberType Type );
Parameters
- bsName
The e-mail address or named workflow role to be added.- Type
The type of member specified in bsName: cdowfEmailAddress (0), or cdowfRole (1).
Return Value
Returns S_OK if successful, or an error value otherwise.
Remarks
The name you add must be one of the following two types.
Name Type "someone@example.com" cdowfEmailAddress (0) "Role1" ... "Role16" cdowfRole (1) While "someone@example.com" is a fictitious name, "Role1" through "Role16" are literal names and are the only ones valid for type cdowfRole. The Add method has different effects depending on which collection you are adding members to.
Collection Effect of Add method ItemAuthors Extends or adds to the folder default. Any members you add are in addition to those allowed to modify and delete items by folder default role. ItemReaders Replaces the folder default. Only those members you add are allowed access to the item. If ItemReaders Property has no members, the folder default applies.
Example
This example adds a user to the IWorkflowSession Interface, ItemAuthors Property collection.
emAddress = "someone@example.com" WorkflowSession.ItemAuthors.Add emAddress, 0 'cdowfEmailAddress
See Also
Send us your feedback about the Microsoft Exchange Server 2003 SDK.
Build: June 2007 (2007.618.1)
© 2003-2006 Microsoft Corporation. All rights reserved. Terms of use.