NSIS:如何检查应用程序安装

问题描述 投票:0回答:1

我需要检查是否安装了Microsoft过滤器包2.0应用程序。我发现this答案,但在我的情况我没有应用程序的名称,而不是在注册表程序命名为{95140000-2000-0409-1000-0000000FF1CE}这里是我的代码来检测安装的应用程序名称目录:

ReadRegStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${FILTER_PACK_KEY}" "UninstallString"
IfErrors FilterPackNotFound FilterPackFound
nsis regedit
1个回答
1
投票

在64位Windows注册表有two "views"和32位应用程序的默认访问32位视图。

NSIS可以通过使用SetRegView指令访问的64位图:

Section
SetRegView 64
RegReadStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\{95140000-2000-0409-1000-0000000FF1CE}" "UninstallString"
SetRegView 32
MessageBox mb_ok $0
SectionEnd
© www.soinside.com 2019 - 2024. All rights reserved.