| CustodianManagerDelete Method |
Delete one more custodians
Caution |
---|
Deleting a custodian will also delete all the sources for each custodian, and by
extension all the documents and metadata for those sources.
|
Namespace:
Law.EdaIntegration.Import
Assembly:
Law.EdaIntegration (in Law.EdaIntegration.dll) Version: 7.2
Syntax public void Delete(
List<int> custodianIdsToDelete
)
Parameters
- custodianIdsToDelete
- Type: System.Collections.GenericListInt32
The list of unique identifiers of the custodians to be deleted
Examples
This example demonstrates deleting a custodian.
using Law.EdaIntegration;
using Law.EdaIntegration.Case;
using Law.EdaIntegration.Import;
class Sample
{
public static void Main()
{
string connectionString = @"Data Source=localhost;Initial Catalog=EDA_Management;Integrated Security=False;User ID=myUserId;Password=myPassword";
EdaIntegration edaIntegration = new EdaIntegration();
edaIntegration.InitializeEnvironment(connectionString);
Case edaCase = edaIntegration.Cases.OpenCaseByName("Case 1");
Custodian custodian = edaCase.Custodians.ByName("Custodian 3");
Console.WriteLine("({0}) {1}", custodian.Id, custodian.Name);
List<int> custodiansToDelete = new List<int> { custodian.Id };
edaCase.Custodians.Delete(custodiansToDelete);
Console.WriteLine("Custodian deleted");
try
{
custodian = edaCase.Custodians.ByName("Custodian 3");
}
catch (EdaApiException ex)
{
Console.WriteLine("Exception: {0}", ex.Message);
}
}
}
See Also