lower case. (The directory portion is okay, just the leaf file name is
broken.)
I found this thread from 6/02 stating as such, and a reply presenting a
workaround.
However, creating a DirectoryInfo or FileInfo object with the path and
asking for the Name or FullName still reports the lower case version, not
the correct user case.
Any ideas short of opening the file's or folder's parent dir, enumerating
all the files, comparing w/o case, and returning the matching entry? (Not
that's it's hard, just hoping for a better way...)
thanks,
mike
..Net 1.1.4372
---------------------
Here is the fix for that bug
Pass the FullPath into the Constructor of a DirectoryInfo Class and Read the
Name Property.
--
Joe Feser
"Michael" <Mi*****@nowhere.com> wrote in message
news:eySuyptHCHA.2012@tkmsftngp13...
Is there an official place to submit this bug?
I'm not sure which of the two classes would be the source of the problem.
"System.IO.FileSystemEventArgs" or "System.IO.FileSystemWatcher"
to recreate:
1) Initialize a "System.IO.DirectoryInfo" instance to a folder name that has capital letters.
IE.
System.IO.DirectoryInfo dir = new System.IO.DirectoryInfo("C:\New
Folder");
2) create the directory...
dir.Create();
3) create a "FileSystemWatcher" object to monitor the location where you
create the new folder.
4) in the Created event handler for the "FileSystemWatcher", examine the
"FileSystemEventArgs", property "FullPath" or "Name". You'll notice that
replaces all characters in the newly created portion of the "FullPath" with lower case letters.
Now when you display the name in a listview, it is forced to lower case. I
know this is going to annoy my users.