挂断了一段期间COM去登记,并说The setup was unable to automatically close all requested applications. Please ensure that the applications holding files in use are closed before continuing with the installation
。但实际上,我的扩展程序已成功卸载并卸载。环境
定义:
我创建某种虚拟外壳命名空间扩展测试。它实现IContextMenu
和所有方法返回S_OK
和别的什么也不做和RGS文件是
HKCR
{
xxx.sergz.dummyShellExt.1 = s 'DummyNSE Class'
{
CLSID = s '{6C0FBE00-9898-4BB0-806F-3ED7D2F1170D}'
}
xxx.sergz.dummyShellExt = s 'DummyNSE Class'
{
CurVer = s 'xxx.sergz.dummyShellExt.1'
}
NoRemove CLSID
{
ForceRemove {6C0FBE00-9898-4BB0-806F-3ED7D2F1170D} = s 'DummyNSE Class'
{
ProgID = s 'xxx.sergz.dummyShellExt.1'
VersionIndependentProgID = s 'xxx.sergz.dummyShellExt'
ForceRemove Programmable
InprocServer32 = s '%MODULE%'
{
val ThreadingModel = s 'Apartment'
}
TypeLib = s '{3DC947F0-6691-4043-B414-29F749209905}'
Version = s '1.0'
}
}
NoRemove Directory
{
NoRemove Background
{
NoRemove ShellEx
{
NoRemove ContextMenuHandlers
{
ForceRemove DummyShellExt = s '{6C0FBE00-9898-4BB0-806F-3ED7D2F1170D}'
}
}
}
}
}
HKLM
{
NoRemove Software
{
NoRemove Microsoft
{
NoRemove Windows
{
NoRemove CurrentVersion
{
NoRemove Shell Extensions
{
NoRemove Approved
{
val '{6C0FBE00-9898-4BB0-806F-3ED7D2F1170D}' = s 'xxx.sergz Dummy shell extension.'
}
}
}
}
}
}
}
我选择Professional
安装程序,只增加了我的dll文件。在文件属性Registration
选项卡上,我选择Auto register file...
,Extract registration info...
和Synchronization
为Enabled
。在Product Information->Install Parameters->PackageType
我选择64-bit package for x64...
。
现在我构建MSI并安装扩展。 启动资源管理器,然后在文件夹背景上的某处执行右键单击。根据我的日志,我的扩展程序被加载并且是DLL_PROCESS_ATTACH和几次DLL_THREAD_ATTACH。
我再次启动MSI并选择Remove
。它说你必须关闭... applications are using files...
,并且列表中只有Windows Explorer
。我选择Automatically close ...
并按OK。
所有资源管理器窗口已关闭,但似乎资源管理器未关闭。
状态是“关闭应用程序”,根据我的日志dll已经卸载。问题在这里。该DLL已经卸载,但MSI仍在等待,然后它说The setup was unable to automatically close all requested applications. Please ensure that the applications holding files in use are closed before continuing with the installation
。 我点击确定,这个过程继续进行,最终我的DLL被成功删除。
我使用Windows 8 64位。
这种等待的原因是什么以及应用程序无法关闭的消息。我怎么弄出来的?
“专业安装程序” - > http://advancedinstaller.com/user-guide/tutorial-professional.html。我可以使用WiX,但问题是关于高级安装程序。实际上也有相同的情况,根据重现问题的步骤,高级安装程序从DLL中提取rgs,我不使用自注册/注销。该DLL也可以立即被删除,无需重新登录。这是一个安装工具的问题,它要求用户使用打开的文件自动关闭应用程序或重新启动计算机。 – SergZ 2013-04-06 06:56:48