PowerShell Logo Small


This is the built-in help made by Microsoft for the command 'Add-RDVirtualDesktopToCollection', in PowerShell version 5 - as retrieved from Windows version 'Microsoft Windows Server 2012 R2 Standard' PowerShell help files on 2016-06-23.

For PowerShell version 3 and up, where you have Update-Help, this command was run just before creating the web pages from the help files.


Adds virtual desktops to a virtual desktop collection.


Add-RDVirtualDesktopToCollection [-CollectionName] <String> [-ConnectionBroker <String>] [-VirtualDesktopPasswordAge <Int32>] -VirtualDesktopAllocation <Hashtable>
Add-RDVirtualDesktopToCollection [-CollectionName] <String> [-ConnectionBroker <String>] [-VirtualDesktopTemplateHostServer <String>] [-VirtualDesktopTemplateName <String>]
-VirtualDesktopAllocation <Hashtable> [<CommonParameters>]
Add-RDVirtualDesktopToCollection [-CollectionName] <String> [-ConnectionBroker <String>] -VirtualDesktopName <String[]> [<CommonParameters>]

Search powershellhelp.space


The Add-RDVirtualDesktopToCollection cmdlet adds one or more virtual desktops to a virtual desktop collection. You can use this cmdlet to add virtual desktops to personal
virtual desktop collections, managed pooled virtual desktop collections, and unmanaged pooled virtual desktop collections.



Online Version: http://go.microsoft.com/fwlink/?LinkId=294205




Example 1: Add virtual desktops to a virtual desktop collection on an RD Connection Broker

PS C:\> Add-RDVirtualDesktopToCollection -ConnectionBroker "rdcb.contoso.com" -CollectionName "Virtual Desktop Pool" -VirtualDesktopAllocation
@{"RDS-WKS-A27.vdi.contoso.com"=1;"RDS-WKS-A28.vdi.contoso.com"=2} -VirtualDesktopPasswordAge 31

This command adds virtual desktops to the managed pooled virtual desktop collection named "Virtual Desktop Pool" that is associated with the RD Connection Broker server
named "rdcb.contoso.com". The VirtualDesktopAllocation parameter specifies that one virtual desktop is created on the host servers named "RDS-WKS-A27.vdi.contoso.com" and
two virtual desktops are created on the host server named "RDS-WKS-A28.vdi.contoso.com". The command specifies that after 31 days the server enforces a password update for
the virtual desktops.