OrganizationServiceContextExtensions.DetachLink Method (OrganizationServiceContext, Entity, String, Entity, Nullable<EntityRole>)


Applies To: Dynamics CRM 2015

Detaches a two entity instances.

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


public static bool DetachLink(
    this OrganizationServiceContext context,
    Entity source,
    string relationshipSchemaName,
    Entity target,
    Nullable<EntityRole> primaryEntityRole = null
static bool DetachLink(
    OrganizationServiceContext^ context,
    Entity^ source,
    String^ relationshipSchemaName,
    Entity^ target,
    Nullable<EntityRole> primaryEntityRole = null
static member DetachLink : 
        context:OrganizationServiceContext *
        source:Entity *
        relationshipSchemaName:string *
        target:Entity *
        primaryEntityRole:Nullable<EntityRole> = null -> bool
Public Shared Function DetachLink (
    context As OrganizationServiceContext,
    source As Entity,
    relationshipSchemaName As String,
    target As Entity,
    primaryEntityRole As Nullable(Of EntityRole)
) As Boolean


  • relationshipSchemaName
    Type: System.String

    Type: String. The schema name of the relationship.

Return Value

Type: System.Boolean

Type: Boolean


This is an extension to the core DetachLink method.

See Also

DetachLink Overload
OrganizationServiceContextExtensions Class
Microsoft.Xrm.Client Namespace

Return to top

© 2017 Microsoft. All rights reserved. Copyright