< Back
Get-CrmEntityOptionSet
Post
NAME Get-CrmEntityOptionSet
SYNOPSIS
Retrieves a picklist field of an Entity.
SYNTAX
Get-CrmEntityOptionSet [-conn <CrmServiceClient>] [-EntityLogicalName] <String> [-FieldLogicalName] <String>
[<CommonParameters>]
DESCRIPTION
The Get-CrmEntityOptionSet cmdlet lets you retrieve a picklist field of an Entity.
PARAMETERS
-conn <CrmServiceClient>
A connection to your CRM organization. Use $conn = Get-CrmConnection <Parameters> to generate it.
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-EntityLogicalName <String>
A logicalname for Entity. i.e.)account, contact, lead, etc..
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
-FieldLogicalName <String>
A logicalname for a picklist filed.
Required? true
Position? 2
Default value
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
NOTES
-------------------------- Example 1 --------------------------
Get-CrmEntityOptionSet -conn $conn -EntityLogicalName account -FieldLogicalName statuscode
This example retrieves statuscode picklist for Account Entity.
ActualValue PickListLabel DisplayValue Items
----------- ------------- ------------ -----
Status Reason {1, 2}
-------------------------- Example 2 --------------------------
Get-CrmEntityOptionSet account statuscode
This example retrieves statuscode picklist for Account Entity by omitting parameter names.
When omitting parameter names, you do not provide $conn, cmdlets automatically finds it.
ActualValue PickListLabel DisplayValue Items
----------- ------------- ------------ -----
Status Reason {1, 2}
-------------------------- Example 3 --------------------------
Get-CrmEntityOptionSet account statuscode | % {$_.Items}
This example retrieves statuscode picklist for Account Entity and displays Label and Id.
DisplayLabel PickListItemId
------------ --------------
Active 1
Inactive 2
RELATED LINKS
SYNOPSIS
Retrieves a picklist field of an Entity.
SYNTAX
Get-CrmEntityOptionSet [-conn <CrmServiceClient>] [-EntityLogicalName] <String> [-FieldLogicalName] <String>
[<CommonParameters>]
DESCRIPTION
The Get-CrmEntityOptionSet cmdlet lets you retrieve a picklist field of an Entity.
PARAMETERS
-conn <CrmServiceClient>
A connection to your CRM organization. Use $conn = Get-CrmConnection <Parameters> to generate it.
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-EntityLogicalName <String>
A logicalname for Entity. i.e.)account, contact, lead, etc..
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
-FieldLogicalName <String>
A logicalname for a picklist filed.
Required? true
Position? 2
Default value
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
NOTES
-------------------------- Example 1 --------------------------
Get-CrmEntityOptionSet -conn $conn -EntityLogicalName account -FieldLogicalName statuscode
This example retrieves statuscode picklist for Account Entity.
ActualValue PickListLabel DisplayValue Items
----------- ------------- ------------ -----
Status Reason {1, 2}
-------------------------- Example 2 --------------------------
Get-CrmEntityOptionSet account statuscode
This example retrieves statuscode picklist for Account Entity by omitting parameter names.
When omitting parameter names, you do not provide $conn, cmdlets automatically finds it.
ActualValue PickListLabel DisplayValue Items
----------- ------------- ------------ -----
Status Reason {1, 2}
-------------------------- Example 3 --------------------------
Get-CrmEntityOptionSet account statuscode | % {$_.Items}
This example retrieves statuscode picklist for Account Entity and displays Label and Id.
DisplayLabel PickListItemId
------------ --------------
Active 1
Inactive 2
RELATED LINKS