共用方式為


OrganizationServiceContext.LoadProperty 方法 (Entity, Relationship)

適用於: CRM 2015 on-prem, CRM Online

Loads the related entity collection for the specified relationshp.

命名空間: Microsoft.Xrm.Sdk.Client
組件: Microsoft.Xrm.Sdk (在 Microsoft.Xrm.Sdk.dll 中)

語法

'宣告
Public Sub LoadProperty ( _
    entity As Entity, _
    relationship As Relationship _
)
public void LoadProperty (
    Entity entity,
    Relationship relationship
)

參數

  • entity
    Type: Entity. The entity with the relationship to be loaded.
  • relationship
    Type: Relationship. The name of the attribute or navigation property on the entity that represents the relationship to be retrieved.

備註

Calling this method invokes a network operation to retrieve the property value. The property specified may be any one of the properties on the entity, including properties that represent associations or links.If the property represents an association, link or deferred property, calling this method provides the client a way to lazily load related resources. If the entity is in the unchanged or modified state, the property value loads the related entities and marks them unchanged with unchanged links. If the property is already loaded, calling this method lets you refresh the value of the property.

執行緒安全

此類型的任何公用靜態 (Visual Basic 中的 Shared) 成員都具備執行緒安全。任何執行個體成員都不保證具備執行緒安全。

平台

開發平台

Windows Vista、Windows Server 2003 和

目標平台

Windows Vista、Windows XP

請參閱

參照

OrganizationServiceContext 類別
OrganizationServiceContext 成員
Microsoft.Xrm.Sdk.Client 命名空間

Send comments about this topic to Microsoft.
© 2014 Microsoft Corporation. All rights reserved.