N
Nathan Baulch
Given an arbitary qualified file name which is guarenteed to exist:
"C:\WiNdOwS\MicROSoft.NeT\framEoRK\v1.1.4322\AcceSSibility.dLl"
I would like some means of getting the correct text case, as per the file
system:
"C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\Accessibility.dll"
I can get a string with just the file name portion with the correct case:
string qualifiedFileName = Directory.GetFiles(
Path.GetDirectoryName(qualifiedFileName),
Path.GetFileName(qualifiedFileName))[0];
The only method I can think of to get the correct case for the directory
portion is to loop through each sub directory and use
Directory.GetDirectories() with a filter (similar to my usage of
Directory.GetFiles() above).
Is there a simpler way?
Nathan
"C:\WiNdOwS\MicROSoft.NeT\framEoRK\v1.1.4322\AcceSSibility.dLl"
I would like some means of getting the correct text case, as per the file
system:
"C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\Accessibility.dll"
I can get a string with just the file name portion with the correct case:
string qualifiedFileName = Directory.GetFiles(
Path.GetDirectoryName(qualifiedFileName),
Path.GetFileName(qualifiedFileName))[0];
The only method I can think of to get the correct case for the directory
portion is to loop through each sub directory and use
Directory.GetDirectories() with a filter (similar to my usage of
Directory.GetFiles() above).
Is there a simpler way?
Nathan