I couldn't find any information on this through professor Google, so here I am. Take the given path name and paste it into Windows Explorer. I stumbled across this after discovering bug in my code that generated the paths with an extra '.' in the path name before a directory \
separator...
@"C:\\pathto.\file.ext"
In code, .NET will accept the path when calling File.Create
and a file will be generated, but at this path:
@"C:\\pathto\file.ext"
Copying C:\\pathto.\file.ext
into Windows Explorer's address bar and watch the '.' disappear and take you to C:\\pathto\file.ext
Is it normal behavior for .NET and Windows to It's not causing an issue because the '.' is being removed by both .NET and Windows when passed into file operations. The real issue is that all the files in the DB have filenames with a '.\', but exists in paths that do not have a '.\'... and File.Exists()
works too, although the path is not the 'real' physical location...
What's going on here?