OrganizationServiceContextExtensions.MergeClone<T> Method (OrganizationServiceContext, T, Boolean)


Applies To: Dynamics CRM 2015

Clones an arbitrary source entity and attaches it to the context.

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


public static T MergeClone<T>(
    this OrganizationServiceContext context,
    T entity,
    bool includeRelatedEntities = false
where T : Entity
generic<typename T>
where T : Entity
static T MergeClone(
    OrganizationServiceContext^ context,
    T entity,
    bool includeRelatedEntities = false
static member MergeClone<'T when 'T : Entity> : 
        context:OrganizationServiceContext *
        entity:'T *
        includeRelatedEntities:bool = false -> 'T
Public Shared Function MergeClone(Of T As Entity) (
    context As OrganizationServiceContext,
    entity As T,
    includeRelatedEntities As Boolean
) As T


  • entity
    Type: T

    Type: T. The entity instance.

  • includeRelatedEntities
    Type: System.Boolean

    Type: Boolean. Specifies whether to include related entity instances.

Return Value

Type: T

Type: Boolean

Type Parameters

  • T
    The type, where T is Type: Entity.

See Also

OrganizationServiceContextExtensions Class
Microsoft.Xrm.Client Namespace
Developer extensions for Microsoft Dynamics CRM 2015
Developer extensions context object model (Dynamics CRM 2015)

Return to top

© 2017 Microsoft. All rights reserved. Copyright