besides Win32::.*? functions there is also Win32API::File that looks quite confusing to me. It says to be using 'low level' functions so maybe also a way to get those short file names (like "PROGRA~1" for "Program Files") that should be useful for your task.