CSharp File IO Directory

CSharp examples for File IO:Directory

Description

Click the following links for the tutorial for File IO and Directory.

  1. Calculate the Size of a Directory
  2. Find Files That Match a Wildcard Expression
  3. Get the Total Free Space on a Drive
  4. delete a directory
  5. create a directory
  6. check if a directory exists
  7. Get Files from folder
  8. Provides a file folder chooser dialog


  9. Delete Directory Files
  10. Directory.Delete does not delete individual files within the directory structure.
  11. Safely copies file, creating all necessary directories and overwriting destination.
  12. Is file Compressed
  13. Get Files Recursive
  14. Non Recursive Get Files
  15. Directory Is Exists
  16. Ensures that a directory exists, creating it if it doesn't.


  17. Checks if the specified directory exists and create it if not present.
  18. Clean Directory
  19. Check Directory by path and extension
  20. Copy Directory
  21. Copies a directory.
  22. Recursively copies a directory from one path to another, while creating any parent directories if they don't already exist.
  23. Moves a directory from one path to another, while creating any parent directories if they don't already exist.
  24. Recursive directory deletion that handles directories being opened in Windows Explorer. Source: http:stackoverflow.coma1703799
  25. Recurse search a directory
  26. List Directory by extension
  27. Delete directory by pattern
  28. Delete directory, if include the root
  29. Creates a directory at the given path, if it's not existing
  30. Creates a random directory structure to the specified depth, where each folder has a random name of the specified length with the available chars.
  31. Get Directory Parallel
  32. Copy Directory Recursive Internal
  33. Is Same Directory
  34. Remove first directory of path (if one exists). e.g. "maps\\my maps\\he.map" becomes "my maps\\he.map"
  35. Clear Directory
  36. Safely copies all content from one directory to another.
  37. ReName Folder
  38. Copy folder recursive
  39. Ensure Folder Exists
  40. Force Delete folder
  41. Copy folder with pattern
  42. Get Folder Size
  43. Returns true when child Folder is a sub folder of parent Folder
  44. Check if a folder is a direct sub folder of a main folder.
  45. Get Folder To Open using FolderBrowserDialog
  46. Create Directories
  47. Create Dir
  48. Delete Dir
  49. Splits a path into all parts of its directories, e.g. "maps\\sub\\the" becomes {"maps\\sub\\the","maps\\sub","maps"}
  50. Ensure Parent Exists
  51. Calculates the best fragment size to be split.