SharedWorkspaceMembers.Add Method
Adds a member to the list of members in a shared workspace site. Returns a SharedWorkspaceMember object.
Syntax
expression.Add(Email, DomainName, DisplayName, Role)
expression Required. A variable that represents a SharedWorkspaceMembers object.
Parameters
| Name | Required/Optional | Data Type | Description |
|---|---|---|---|
| Required | String | The new member's e-mail address in the format user@domain.com. Raises an error if the user is not a valid candidate for membership in the shared workspace site. | |
| DomainName | Required | String | The new member's Windows user name in the format domain\user. |
| DisplayName | Required | String | The display name to display for the new member. |
| Role | Optional | String | An optional role that determines the tasks the new member can accomplish in the shared workspace site; for example, "Contributor". An invalid role name raises an error. |
Example
The following example adds a new member to the members collection of the shared workspace site in the role of a site contributor.
| Visual Basic for Applications |
|---|
|