You can use System.IO.Directory.GetParent()
to retrieve the parent directory of a given directory.
More Related Contents:
- How to get a path to the desktop for current user in C#?
- How do I detect when a directory or file changes without constant scanning
- Can you call Directory.GetFiles() with multiple filters?
- How to remove illegal characters from path and filenames?
- Checking for directory and file write permissions in .NET
- Wait Until File Is Completely Written
- Copy the entire contents of a directory in C#
- Getting the absolute path of the executable, using C#?
- How can I compare (directory) paths in C#?
- Getting all file names from a folder using C# [duplicate]
- Unique file identifier in windows
- Zip folder in C#
- Microsoft Azure: How to create sub directory in a blob container
- How can I list the contents of a .zip folder in c#?
- Determining if file exists using c# and resolving UNC path
- Getting Downloads Folder in C#? [duplicate]
- Retrieving files from directory that contains large amount of files
- What is the best way to get the executing exe’s path in .NET?
- Atomicity of File.Move
- How do I get the directory from a file’s full path?
- List all files and directories in a directory + subdirectories
- Get folder name from full file path
- DotNetZip add files without creating folders
- Properties.Settings.Default.Save(); -> Where is that file
- Delete files older than 3 months old in a directory using .NET
- Where is the correct place to store my application specific data?
- .Net’s Directory Services throws a strange exception
- C# Searching for files and folders except in certain folders
- Find a file within all possible folders?
- How can I find the size of all files located inside a folder?