Set-MceUser

SYNOPSIS#

Updates the properties of an MCE user.

SYNTAX#

Set-MceUser [-Id] <String> [[-DisplayName] <String>] [[-IsEnabled] <Boolean>]
[[-LinkedUserIdentities] <PSListModifier>] [<CommonParameters>]

DESCRIPTION#

This cmdlet updates individual properties of a user.

The cmdlet is designed to support pipelining from Get-MceUser.

EXAMPLES#

EXAMPLE 1#

Set-MceUser -Id "4f55b2be-1c07-4fcb-8c66-db563fd46206" -DisplayName "James Smith"

Updates the display name for a user.

EXAMPLE 2#

Set-MceUser -Id "4f55b2be-1c07-4fcb-8c66-db563fd46206" -DisplayName $null

Clears the display name for a user.

EXAMPLE 3#

Set-MceUser -Id "4f55b2be-1c07-4fcb-8c66-db563fd46206" -IsEnabled $true

Enables a user.

EXAMPLE 4#

Set-MceUser -Id "4f55b2be-1c07-4fcb-8c66-db563fd46206" -DisplayName "James Smith" -IsEnabled $true

Enables a user and updates their display name.

EXAMPLE 5#

Get-MceUser | Set-MceUser -IsEnabled $true

Enables all users.

EXAMPLE 6#

$LinkedIdentity = [pscustomobject]@{IdentityProviderId="AD"; Name="objectGuid"; Value="88424234-8752-41fb-b8c7-8c8048ea061a"}
Set-MceUser -Id "4f55b2be-1c07-4fcb-8c66-db563fd46206" -LinkedUserIdentities @{Add=@($LinkedIdentity)}

Adds a linked user identity to a user.

EXAMPLE 7#

$LinkedIdentity = [pscustomobject]@{IdentityProviderId="AD"; Name="objectGuid"; Value="88424234-8752-41fb-b8c7-8c8048ea061a"}
Set-MceUser -Id "4f55b2be-1c07-4fcb-8c66-db563fd46206" -LinkedUserIdentities @{Remove=@($LinkedIdentity)}

Removes a linked user identity from a user.

EXAMPLE 8#

$AddLinkedIdentity = [pscustomobject]@{IdentityProviderId="AD"; Name="objectGuid"; Value="88424234-8752-41fb-b8c7-8c8048ea061a"}
$RemoveLinkedIdentity = [pscustomobject]@{IdentityProviderId="OP"; Name="otherAttribute"; Value="33a16fea-6124-4b5b-9378-5f959f60ffb8"}
Set-MceUser -Id "4f55b2be-1c07-4fcb-8c66-db563fd46206" -LinkedUserIdentities @{Add=@($AddLinkedIdentity), Remove=@($RemoveLinkedIdentity)}

Removes a linked user identity from a user.

EXAMPLE 9#

$LinkedIdentity = [pscustomobject]@{IdentityProviderId="AD"; Name="objectGuid"; Value="88424234-8752-41fb-b8c7-8c8048ea061a"}
Set-MceUser -Id "4f55b2be-1c07-4fcb-8c66-db563fd46206" -LinkedUserIdentities @{Replace=@($LinkedIdentity)}

Replaces the linked user identities for a user.

PARAMETERS#

-Id#

The user ID.

Type: String
Parameter Sets: (All)
Aliases:
Required: True
Position: 0
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-DisplayName#

The user display name or null or to clear the display name. Note that this has no effect on display names synchronized from external identity providers.

Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-IsEnabled#

The enabled state.

Type: Boolean
Parameter Sets: (All)
Aliases:
Required: False
Position: 2
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-LinkedUserIdentities#

The linked user identities.

Type: PSListModifier
Parameter Sets: (All)
Aliases:
Required: False
Position: 3
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

CommonParameters#

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS#

System.String#

The user ID.

System.Management.Automation.PSListModifier#

The linked user identities.

OUTPUTS#

None#

NOTES#

RELATED LINKS#

MindLink Docs