Share via


EntityReference Constructors

Definition

Overloads

EntityReference()

Initializes a new instance of the EntityReference class.

EntityReference(String)

Initializes a new instance of the EntityReference class.

EntityReference(String, KeyAttributeCollection)

Initializes a new instance of the EntityReference class.

This constructor was introduced with Microsoft Dynamics CRM Online 2015 Update 1 and cannot be used with earlier versions.

EntityReference(String, Guid)

Initializes a new instance of the EntityReference class setting the logical name and entity ID.

This constructor was introduced with Microsoft Dynamics CRM Online 2015 Update 1 and cannot be used with earlier versions.

EntityReference(String, String, Object)

Initializes a new instance of the EntityReference class.

This constructor was introduced with Microsoft Dynamics CRM Online 2015 Update 1 and cannot be used with earlier versions.

EntityReference()

Initializes a new instance of the EntityReference class.

public:
 EntityReference();
public EntityReference ();
Public Sub New ()

Applies to

EntityReference(String)

Initializes a new instance of the EntityReference class.

public:
 EntityReference(System::String ^ logicalName);
public EntityReference (string logicalName);
new Microsoft.Xrm.Sdk.EntityReference : string -> Microsoft.Xrm.Sdk.EntityReference
Public Sub New (logicalName As String)

Parameters

logicalName
String

Specifies the logical name.

Applies to

EntityReference(String, KeyAttributeCollection)

Initializes a new instance of the EntityReference class.

This constructor was introduced with Microsoft Dynamics CRM Online 2015 Update 1 and cannot be used with earlier versions.

public:
 EntityReference(System::String ^ logicalName, Microsoft::Xrm::Sdk::KeyAttributeCollection ^ keyAttributeCollection);
public EntityReference (string logicalName, Microsoft.Xrm.Sdk.KeyAttributeCollection keyAttributeCollection);
new Microsoft.Xrm.Sdk.EntityReference : string * Microsoft.Xrm.Sdk.KeyAttributeCollection -> Microsoft.Xrm.Sdk.EntityReference
Public Sub New (logicalName As String, keyAttributeCollection As KeyAttributeCollection)

Parameters

logicalName
String

Specifies the entity logical name.

keyAttributeCollection
KeyAttributeCollection

Specifies the key attributes collection.

Remarks

This constructor was introduced with Microsoft Dynamics CRM Online 2015 Update 1 and cannot be used with earlier versions.

Applies to

EntityReference(String, Guid)

Initializes a new instance of the EntityReference class setting the logical name and entity ID.

This constructor was introduced with Microsoft Dynamics CRM Online 2015 Update 1 and cannot be used with earlier versions.

public:
 EntityReference(System::String ^ logicalName, Guid id);
public EntityReference (string logicalName, Guid id);
new Microsoft.Xrm.Sdk.EntityReference : string * Guid -> Microsoft.Xrm.Sdk.EntityReference
Public Sub New (logicalName As String, id As Guid)

Parameters

logicalName
String

The logical name of the entity.

id
Guid

The ID of the record.

Remarks

This constructor was introduced with Microsoft Dynamics CRM Online 2015 Update 1 and cannot be used with earlier versions.

Applies to

EntityReference(String, String, Object)

Initializes a new instance of the EntityReference class.

This constructor was introduced with Microsoft Dynamics CRM Online 2015 Update 1 and cannot be used with earlier versions.

public:
 EntityReference(System::String ^ logicalName, System::String ^ keyName, System::Object ^ keyValue);
public EntityReference (string logicalName, string keyName, object keyValue);
new Microsoft.Xrm.Sdk.EntityReference : string * string * obj -> Microsoft.Xrm.Sdk.EntityReference
Public Sub New (logicalName As String, keyName As String, keyValue As Object)

Parameters

logicalName
String

Specifies the entity logical name.

keyName
String

Specifies the key name.

keyValue
Object

Specifies the key value.

Remarks

This constructor was introduced with Microsoft Dynamics CRM Online 2015 Update 1 and cannot be used with earlier versions.

Applies to