PDA

View Full Version : GetFileVersion() bug...


jassing
03-06-2007, 02:30 PM
On win9x, when accessing long file names on a remote drive, File.GetVersionInfo() fails.

local tFile = Dialog.FileBrowse(true, "File Name", _TempLaunchFolder, "Executables|*.*", "", "exe", false, true);
Application.SetLastError(0);
local tInfo = File.GetVersionInfo(tFile[1]);
if tInfo then
if Dialog.Message("Success!", tFile[1].."\r\nis version "..tInfo.FileVersion.."\r\nDo another?", MB_YESNO, MB_ICONINFORMATION, MB_DEFBUTTON2) == IDNO then
Application.Exit(1);
end
else
if Dialog.Message("Ooops", "File.GetVersion() failed for\r\nfile "..tFile[1].."\r\n".. _tblErrorMessages[Application.GetLastError()] .."\r\nTry again?", MB_YESNO, MB_ICONSTOP, MB_DEFBUTTON1) == IDNO then
Application.Exit(2);
end
end


When I run that code, and select a file locally; it fails with
Could not get the size of the version information.

if I copy that same file to the local drive, no problem.
If I rename to a short filename and leave on teh remote drive, no problem.

SO.. issue seems to be


Win9x
Network/Remove drive
Filename has to be Long ("SupportWizard.exe" vs. short "supwiz.exe")

jassing
03-06-2007, 02:51 PM
When I run that code, and select a file locally; it fails with
Could not get the size of the version information.


That should have read:

When I run that code, and select a file remotely; it fails...

Adam
03-08-2007, 12:44 PM
I have logged this one. REF: 14992

Adam Kapilik

jassing
03-08-2007, 12:51 PM
I have logged this one. REF: 14992

I feel bad asking -- is there an ETA on some of these bugs to be fixed/updated/patched?