获取文件版本信息

!include "FileVerInfo.nsh"
Name "GetFileVerInfo"
Caption "$(^Name)"
OutFile "GetFileVerInfo.exe"
XPStyle on
Function .onGUIInit
 StrCpy $0 "文件 $WINDIRnotepad.exe 的版本信息:$r$n"
 ${GetProductName} "$WINDIRnotepad.exe" $R0
 StrCpy $0 "$0$r$n - 产品名称 (ProductName): $R0"
 ${GetComments} "$WINDIRnotepad.exe" $R0
 StrCpy $0 "$0$r$n - 备注 (Comments): $R0"
 ${GetCompanyName} "$WINDIRnotepad.exe" $R0
 StrCpy $0 "$0$r$n - 公司 (CompanyName): $R0"
 ${GetLegalCopyright} "$WINDIRnotepad.exe" $R0
 StrCpy $0 "$0$r$n - 版权 (LegalCopyright): $R0"
 ${GetFileDescription} "$WINDIRnotepad.exe" $R0
 StrCpy $0 "$0$r$n - 描述 (FileDescription): $R0"
 ${GetFileVersion} "$WINDIRnotepad.exe" $R0
 StrCpy $0 "$0$r$n - 文件版本 (FileVersion): $R0"
 ${GetProductVersion} "$WINDIRnotepad.exe" $R0
 StrCpy $0 "$0$r$n - 产品版本 (ProductVersion): $R0"
 ${GetInternalName} "$WINDIRnotepad.exe" $R0
 StrCpy $0 "$0$r$n - 内部名称 (InternalName): $R0"
 ${GetLegalTrademarks} "$WINDIRnotepad.exe" $R0
 StrCpy $0 "$0$r$n - 合法商标 (LegalTrademarks): $R0"
 ${GetOriginalFilename} "$WINDIRnotepad.exe" $R0
 StrCpy $0 "$0$r$n - 源文件名 (OriginalFilename): $R0"
 ${GetPrivateBuild} "$WINDIRnotepad.exe" $R0
 StrCpy $0 "$0$r$n - 个人用内部版本说明 (PrivateBuild): $R0"
 ${GetSpecialBuild} "$WINDIRnotepad.exe" $R0
 StrCpy $0 "$0$r$n - 特殊内部版本说明 (SpecialBuild): $R0"
 ${GetUserDefined} "ProductBuild" "$WINDIRnotepad.exe" $R0
 StrCpy $0 "$0$r$n - ProductBuild (自定义版本名): $R0"
 MessageBox MB_OK|MB_ICONINFORMATION $0
 Quit
FunctionEnd
Section -Main
SectionEnd
THE END
喜欢就支持一下吧
点赞8 分享
评论 抢沙发

请登录后发表评论

    暂无评论内容