MetadataExtensions.CreateOrUpdatePickListElement Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Adds an option to a pick list on an entity.
public static bool CreateOrUpdatePickListElement (this Microsoft.PowerPlatform.Dataverse.Client.ServiceClient serviceClient, string targetEntity, string attribName, System.Collections.Generic.List<Microsoft.Xrm.Sdk.LocalizedLabel> locLabelList, int valueData, bool publishOnComplete);
static member CreateOrUpdatePickListElement : Microsoft.PowerPlatform.Dataverse.Client.ServiceClient * string * string * System.Collections.Generic.List<Microsoft.Xrm.Sdk.LocalizedLabel> * int * bool -> bool
<Extension()>
Public Function CreateOrUpdatePickListElement (serviceClient As ServiceClient, targetEntity As String, attribName As String, locLabelList As List(Of LocalizedLabel), valueData As Integer, publishOnComplete As Boolean) As Boolean
Parameters
- serviceClient
- ServiceClient
ServiceClient
- targetEntity
- String
Entity Name to Target
- attribName
- String
Attribute Name on the Entity
- locLabelList
- List<LocalizedLabel>
List of Localized Labels
- valueData
- Int32
integer Value
- publishOnComplete
- Boolean
Publishes the Update to the Live system.. note this is a time consuming process.. if you are doing a batch up updates, call PublishEntity Separately when you are finished.
Returns
true on success, on fail check last error.