I am using ESRI.ArcGIS.DataManagementTools.DeleteFeatures to delete from a File Geodatabase using the Geprocessor object in .NET and it is very slow (minutes).
The same code run against an ArcSDE Geodatabase is fast (seconds).
The GDB is ArcGIS 10 as is the code I am building my .NET app with.
Any thoughts on why this could would run slower against a File Geodatase?
Thanks,
Mele
Below is the code I am using to call DeleteFeatures.
ESRI.ArcGIS.Geoprocessor.GeoprocessorGP = new ESRI.ArcGIS.Geoprocessor.Geoprocessor();
public static void DeleteFCFeatures(IFeatureClass FC)
{
try
{
DeleteFeatures deleteFeatures = new DeleteFeatures();
deleteFeatures.in_features = FC;
ITrackCancel Itrack = null;
RunTool(GP, deleteFeatures, Itrack);
}
catch (Exception ex)
{
Console.WriteLine(ex.Message + "\n\n" + ex.StackTrace);
}
}
private static void RunTool(Geoprocessor geoprocessor, IGPProcess process, ITrackCancel TC)
{
try
{
geoprocessor.Execute(process, null);
processGPMessages(geoprocessor);
}
catch (Exception ex)
{
Console.WriteLine(ex.Message);
processGPMessages(geoprocessor);
}
}