CanBeReferencingRequest

// ** CanBeReferencingRequest **

//Checks whether the specified entity can be the referencing entity in one-to-many

//relationship.

// REQUEST

CanBeReferencingRequest canBereferencingRequest = new CanBeReferencingRequest

{

    EntityName = "referencingEntity(Referencing Entity)"

};

 

// RESPONSE

CanBeReferencingResponse canBeReferencingResponse =

    (CanBeReferencingResponse)_service.Execute(canBereferencingRequest);

 

// Verify RESPONSE

if (!canBeReferencingResponse.CanBeReferencing)

{

    Console.WriteLine(

        "Entity {0} can't be the referencing entity in this one-to-many relationship",

        "referencingEntity(Referencing Entity)");

}