Reputation: 1083
I have created directory and its subdirectory and files... I have to delete them entirely. Is there any possible ways.How can i achieve this
Upvotes: 2
Views: 223
Reputation: 115877
I guess,
Directory.Delete(path, true /* recursive */);
will do the job.
Upvotes: 0
Reputation: 30875
Directory.Delete(path, true);
http://msdn.microsoft.com/en-us/library/fxeahc5f.aspx
Upvotes: 1
Reputation: 64547
Directory.Delete("the dir", true);
http://msdn.microsoft.com/en-us/library/fxeahc5f.aspx
Upvotes: 4