win32api.FindFiles Win2003, problem with Short Name

Neil Hodgson nyamatongwe+thunder at gmail.com
Mon Oct 17 20:14:24 EDT 2005


Frank Borell:

> My initial issue was trying to rename/move files on a SAN that were
> written from Mac's. 

    I've never used a SAN. It is possible that it has its own name 
system and what you are seeing is the result of different views of that.

 > While the easier messed up files names were easy to
> convert and move, I quickly came across a few types that were not.
> Files with spaces at the end seemed to only be solved with the
> win32api.FindFiles(fullpath + '*').

    Does performing a dir /X from the command line show the short names 
from the 2003 system? If so it means that there are APIs capable of 
finding the information so I'd be trying to use ctypes to call the 
underlying wide character FindFirstFileExW function.

> ^2aCOSBY SON PROFILE^2fNYT18|A^2ACOSB.1A7

    This was hex escaped from *COSBY SON PROFILE/NYT18.

    Neil



More information about the Python-list mailing list