Jaa


OrganizationServiceContext.AddRelatedObject Method (Entity, Relationship, Entity)

 

Applies To: Dynamics CRM 2015

Adds a related entity to the OrganizationServiceContext and creates the link that defines the relationship between the two entities in a single request.

Namespace:   Microsoft.Xrm.Sdk.Client
Assembly:  Microsoft.Xrm.Sdk (in Microsoft.Xrm.Sdk.dll)

Syntax

public void AddRelatedObject(
    Entity source,
    Relationship relationship,
    Entity target
)
public:
void AddRelatedObject(
    Entity^ source,
    Relationship^ relationship,
    Entity^ target
)
member AddRelatedObject : 
        source:Entity *
        relationship:Relationship *
        target:Entity -> unit
Public Sub AddRelatedObject (
    source As Entity,
    relationship As Relationship,
    target As Entity
)

Parameters

Remarks

This method essentially works by calling AddObject and AddLink.

See Also

OrganizationServiceContext Class
Microsoft.Xrm.Sdk.Client Namespace

Return to top

© 2016 Microsoft. All rights reserved. Copyright