Command
Set-TeamChannelCopyOptions
Description
The command to set new channel options. Allows the renaming and modification of privacy settings of channels.
Index
Examples
Rename a single channel
$tenant = Connect-Tenant -Domain tenantDomain $team = Get-Team -Name "MyTeam" -Tenant $tenant $channel = Get-TeamChannel -Team $team -Name General $channel = Set-TeamChannelCopyOptions -Channel $channel -NewName GeneralNew
Rename a channel from a list
$tenant = Connect-Tenant -Domain tenantDomain $team = Get-Team -Name "MyTeam" -Tenant $tenant $channels = Get-TeamChannel -Team $team $channels[0] = Set-TeamChannelCopyOptions -Channel $channels[0] -NewName GeneralNew
Rename all channels
$tenant = Connect-Tenant -Domain tenantDomain $team = Get-Team -Name "MyTeam" -Tenant $tenant $channels = Get-TeamChannel -Team $team $channels = $channels | ForEach-Object { Set-TeamChannelCopyOptions -Channel $_ -NewName ($_.Name + "Copied") }
Change the destination privacy of a channel
$tenant = Connect-Tenant -Domain tenantDomain$team = Get-Team -Name "MyTeam" -Tenant $tenant$channel = Get-TeamChannel -Team $team -Name PrivateChannel$channel = Set-TeamChannelCopyOptions -Channel $channel -DesiredDestinationPrivacy Standard
Syntax
Set-TeamChannelCopyOptions-Channel <TeamChannel> -NewName <String>[-DesiredDestinationPrivacy <ChannelDestinationPrivacy {SameAsSource | Standard | Private}>]
Parameters
-Channel <TeamChannel>
Specifies the channels to copy.
Required? | True |
Default value | None |
Accept pipeline input? | True (ByValue, ByPropertyName) |
Accept wildcard characters? | False |
Parameter set name | (All) |
Aliases | None |
-DesiredDestinationPrivacy <ChannelDestinationPrivacy>
Specifies the channel's privacy settings for the destination.
Required? | False |
Default value | SameAsSource |
Accept pipeline input? | False |
Accept wildcard characters? | False |
Parameter set name | (All) |
Aliases | None |
-NewName <String>
Specifies the channel's new name property.
Required? | False |
Default value | None |
Accept pipeline input? | False |
Accept wildcard characters? | False |
Parameter set name | (All) |
Aliases | None |