Come and Check our BETA Alpha version of Powershellcenter.net
Send me your comment to Powershell@powershellcenter.com

Synopsis

Change existing e-mail addresses for an Exchange recipient.

This cmdlet is part of the Quest ActiveRoles Server product. Use Get-QARSProductInfo to view information about ActiveRoles Server.

Syntax

Set-QADProxyAddress [-From] <string> [[-To] <string>] -CurrentAddresses <ProxyAddressChangesUI> [-MakePrimary] [-Confirm] [-WhatIf] [<CommonParameters>]

Set-QADProxyAddress [-From] <string> [[-To] <string>] -DirObject <IGenericDirectoryObject> [-MakePrimary] [-Confirm] [-WhatIf] [<CommonParameters>]

Detailed Description

Use this cmdlet to change an existing e-mail address, or a set of e-mail addresses, for an Exchange recipient. You can set a particular address as the primary or "reply to" address. It is also possible to edit an address, which effectively replaces the old address with the new one. Multiple addresses can be changed at a time by using the asterisk (*) wildcard to represent any string of characters in an e-mail address. This allows you, for example, to change the address suffix for all addresses at a time by identifying the target set of addresses as '*@OldSuffix' and using a pattern of '*@NewSuffix' to specify the desired changes. The cmdlet allows you to identify the Exchange recipient by passing through the pipeline the corresponding output object of a Get-QAD* cmdlet. In this case, the DirObject parameter is used to receive the output object. Another way to identify the Exchange recipient is by passing the output of an *-QADProxyAddress cmdlet, in which case it is the CurrentAddresses parameter that receives the output object (see examples for the Add-QADProxyAddress cmdlet).

Parameters

-CurrentAddresses [<ProxyAddressChangesUI>]

This parameter is intended to receive an output object of an *-QADProxyAddress cmdlet, and is instrumental in a scenario where multiple e-mail address changes need to be applied to a single recipient.

Required?   true
Position?   named
Default value?  
Accept pipeline input?   true (ByValue)
Accept wildcard characters?   false

-DirObject [<IGenericDirectoryObject>]

This parameter is intended to receive the object that represents the Exchange recipient. This could be an output object of a Get-QAD* cmdlet.

Required?   true
Position?   named
Default value?  
Accept pipeline input?   true (ByValue)
Accept wildcard characters?   false

-From [<string>]

Use this parameter to specify the e-mail address or set of e-mail addresses to change. Parameter value can include the asterisk (*) wildcard to match any string of characters. Thus a parameter value of '*@company.com' specifies a set of addresses each of which ends in @company.com.

Required?   true
Position?   1
Default value?  
Accept pipeline input?   false
Accept wildcard characters?   false

-MakePrimary [<SwitchParameter>]

Supply this parameter to set each of the e-mail addresses specified by the From parameter, as the primary or "reply to" address. When the recipient sends an e-mail message, this is the e-mail address that is seen by other users and is the address to which they reply.

A recipient can have multiple e-mail addresses for a specific address type. This allows the recipient to receive messages that are addressed to any one of these e-mail addresses. However, a single address must be designated as the "reply to" address for each address type. An e-mail address that is designated as the "reply to" address is also considered the primary address for the specific address type.

Required?   false
Position?   named
Default value?  
Accept pipeline input?   false
Accept wildcard characters?   false

-To [<string>]

Use this parameter to specify the new address to which you want to change the address specified by the From parameter. You can use the asterisk (*) wildcard in this parameter provided that the asterisk wildcard is also used in the From parameter. The characters that are represented by the asterisk wildcard in this parameter will be identical to the corresponding characters in the From parameter (see examples).

Required?   false
Position?   2
Default value?  
Accept pipeline input?   false
Accept wildcard characters?   false

-Confirm [<SwitchParameter>]

Prompts you for confirmation before executing the command.

Required?   false
Position?   named
Default value?  
Accept pipeline input?   false
Accept wildcard characters?   false

-WhatIf [<SwitchParameter>]

Describes what would happen if you executed the command without actually executing the command.

Required?   false
Position?   named
Default value?  
Accept pipeline input?   false
Accept wildcard characters?   false

Input Type

Return Type

Notes

Examples

EXAMPLE 1

PS> Get-QADUser | Set-QADProxyAddress -From '*@source.com' -MakePrimary

Description

-----------

For all mailbox users, set the e-mail address with a particular suffix as the primary address.

EXAMPLE 2

PS> Get-QADUser | Set-QADProxyAddress -From '*@before.com' -To '*@after.com'

Description

-----------

For all mailbox users, change the e-mail addresses with a particular suffix to replace the existing suffix with a new one.