public bool DeleteDir(string path)
{
bool bdel = false;
try
{
if (System.IO.Directory.Exists(path))
{
System.IO.Directory.Delete(path, true);
bdel = true;
}
else
bdel = false;
}
catch (Exception ex)
{
throw new Exception(ex.Message, ex);
}
return bdel;
}