DirectoryInfo di = new System.IO.DirectoryInfo("DirecotyPath");
FileInfo[] allFiles = di.GetFiles(searchPattern);
foreach (FileInfo file in allFiles)
{
file.Delete();
}
How to Delete files from folder?
Here is code ...........
Labels:
c#
Subscribe to:
Post Comments (Atom)
0 comments:
Post a Comment