Share via


CrmTypes.CreatePickListProperty Method

banner art

Creates an instance of a Picklist attribute represented as a dynamic entity.

Syntax

[Visual Basic .NET]
Public Shared Function CreatePickListProperty(
  ByVal name As String,
  ByVal value As Picklist
) As PicklistProperty

[C#]
public static PicklistProperty CreatePickListProperty(
  string  name,
  Picklist  value
);

[JScript]
public static function CreatePickListProperty(
  name : String,
  value : Picklist
) : PicklistProperty;

Parameters

name

Specifies the name of the attribute.

value

Specifies the value of the attribute.

Return Value

Returns a PicklistProperty type.

Example

[C#]
// Set up the CRM Service.
CrmService service = new CrmService();
service.Credentials 
       = System.Net.CredentialCache.DefaultCredentials;

// Create the PicklistProperty.
PicklistProperty listProp = CrmSdk.CrmTypes.CreatePickListProperty(
                   "prioritycode",
                   1);

See Also

© 2007 Microsoft Corporation. All rights reserved.