Tag Archives: files

Find all Subdirectories from a given path using C#

To load the subdirectories for a given file path. We simply need to use the GetDirectories method of DirectoryInfo (this example loads the results into a listbox lstDirs) E.g. N.B. sPath needs to be a full path including drive letter … Continue reading

Posted in Programming | Tagged , , , , | Leave a comment

Renaming Files using C#

This is an example of how to use C# to rename files. This example takes a passed path e.g. C:\Temp\ and a ‘new name’ and renames all files in the directory with the ‘new name’ plus an underscore and an … Continue reading

Posted in Programming | Tagged , , , | 2 Comments