Problem with FileInfo:GetProductVersion
Hi,
I am stuck and do not seem able to get this bug. I would appreciate any help possible.
I am trying to get the product version for NetMeeting that is installed on my windows XP machine. I use the same function to get another product version, but NetMeeting returns with an empty string. I have right clicked on the CB32.exe file and looked at the properties and they seem to be set with product version 3.01. Any ideas. I checked my inputs and they seem correct.
Here is the key function call code:
;*****************************************************
Function ExeVersionChecker
Pop $versionWanted
Pop $pathAndName
Pop $productName
ClearErrors
IfFileExists "$pathAndName" +4 +1
StrCpy $functResult 'Error: $productName was not found at: "$pathAndName"'
StrCpy $functResult '$functResult$\nConfirm that $productName version "$versionWanted" is present on the system.'
Goto Done
DetailPrint "path and name: $pathAndName"
ClearErrors
FileInfo::GetProductVersion "$pathAndName"
Pop $versionFound
DetailPrint "Version found: $versionFound"
StrCmp "" $versionFound +1 +4
StrCpy $functResult "Error: $productName version number could not be retrieved."
StrCpy $functResult '$functResult$\nConfirm that $productName version "$versionWanted" is present on the system.'
;************************************************
DetailPrint "path and name: $pathAndName" returns the correct path and file name for NetMeeting:
"path and name: C:\Program Files\NetMeeting\CB32.exe"
but this one:
DetailPrint "Version found: $versionFound"
returns:
"Version found: "
Any idea? Microsoft???
Thanks in advance.