Retrieving the AD user or group Information
The Get-User
command is typically used to pipe user or group names into other Horizon View PowerCLI commands.
How to do it…
The following example returns only those AD groups that start with View
:
Get-User -IncludeUser $false -Name "View"
Omit the options to retrieve a list of all users and groups.
How it works…
The following options are available when using the Get-User
command:
The
IncludeUser
option: This sets whether the results include AD user accounts. The options are$False
and$True
(the default).The
IncludeGroup
option: This sets whether the results include AD groups. The options are$False
and$True
(the default).The
Name
option: This is the name of the user or group to be returned. This value should be contained within quotes. If quotes are not used, partial matches are allowed based on the start of the name.The
Domain
option: This will return users or groups from a specific domain.