Export (0) Print
Expand All
Expand Minimize

Remove-CsUnassignedNumber

 

Topic Last Modified: 2012-03-26

Removes an existing range of unassigned numbers and the routing rules that apply to those numbers.

Remove-CsUnassignedNumber -Identity <XdsGlobalRelativeIdentity> [-Confirm [<SwitchParameter>]] [-Force <SwitchParameter>] [-WhatIf [<SwitchParameter>]]

Unassigned numbers are phone numbers that have been assigned to an organization but that have not been assigned to specific users or phones. Microsoft Lync Server 2010 can be set up to route calls to appropriate destinations when an unassigned number is called. This cmdlet removes the settings that define that routing.

Who can run this cmdlet: By default, members of the following groups are authorized to run the Remove-CsUnassignedNumber cmdlet locally: RTCUniversalServerAdmins. To return a list of all the role-based access control (RBAC) roles this cmdlet has been assigned to (including any custom RBAC roles you have created yourself), run the following command from the Windows PowerShell prompt:

Get-CsAdminRole | Where-Object {$_.Cmdlets –match "Remove-CsUnassignedNumber"}

 

Parameter Required Type Description

Identity

Required

XdsGlobalRelativeIdentity

The unique name for the range of unassigned numbers you want to remove.

Force

Optional

SwitchParameter

Suppresses any confirmation prompts that would otherwise be displayed before making changes.

WhatIf

Optional

SwitchParameter

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

Confirm

Optional

SwitchParameter

Prompts you for confirmation before executing the command.

Microsoft.Rtc.Management.Voice.Helpers.DisplayAnnouncementVacantNumberRange object. Accepts pipelined input of unassigned number objects.

This cmdlet does not return a value. It removes an object of type Microsoft.Rtc.Management.Voice.Helpers.DisplayAnnouncementVacantNumberRange.

-------------------------- Example 1 --------------------------

Remove-CsUnassignedNumber -Identity UNSet1

In this example, the unassigned number settings with the Identity UNSet1 are removed.

-------------------------- Example 2 --------------------------

Get-CsUnassignedNumber | Where-Object {$_.AnnouncementName -match "Welcome"} | Remove-CsUnassignedNumber

Example 2 removes all unassigned number settings where the name of the assigned announcement contains the string Welcome. The command begins with a call to Get-CsUnassignedNumber, which returns a collection of all unassigned number settings. This collection is then passed to the Where-Object cmdlet, which narrows down the collection to only those unassigned number settings with an AnnouncementName that includes (-match) the string Welcome. Finally, the narrowed-down collection is passed to Remove-CsUnassignedNumber, which removes everything left in the collection.

 
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft