解决安装程序在win7/vista安装时出现2869的错误
来源:互联网 发布:科罗拉多矿业学院 知乎 编辑:程序博客网 时间:2024/05/01 12:20
vs2005生成安装程序时,想要加入一些动作,比如在安装完成之后弹出一个窗口,或者在结束安装后运行程序,这时需要使用CustomAction,具体操作参见
Vs2005安装程序完成后,自动启动程序 http://blog.hjenglish.com/optop/articles/1208387.html
How can I customize an MSI in the Visual Studio setup/deployment project? http://blogs.msdn.com/astebner/archive/2006/08/12/696833.aspx
最后生成了一个msi文件,在xp下面下使用这个msi文件安装程序一切都正常,但是在win7下时,会报错误2869,<The installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is 2869>
网上找了资料后,发现是 win7/vista的 UAC造成的,具体原因不再探究,下面是查到的解决方案,
Post-Build script to fix MSI issues in Vista for VS 2005 Setup and Deployment Projects
http://blog.csdn.net/sfz_roger/archive/2009/09/02/4508540.aspx
Solution for MSI Error 2869 on Windows Vista
http://blogs.x2line.com/al/archive/2007/07/20/3210.aspx
Windows installer error, Error Code : 2869. msidbCustomActionTypeNoImpersonate
http://social.msdn.microsoft.com/Forums/en-US/windowsgeneraldevelopmentissues/thread/c1326233-3f10-4d98-96a7-4a22e5eeaa2d/
都说需要向 CustomActions添加属性 msidbCustomActionTypeNoImpersonate,不过我没找到直接添加的方式,
后来用了第三个方案就可以了
需要注意的是, 那个需要保存的代码最好保存到 msi生成的目录下,然后cscript NoImpersonate.vbs <msi-file>放到安装项目的 PostBuildEvent事件中
BTW:下面这篇文章讲了下关于与UAC有关的内容,觉得还不错
让您的应用程序更好地适应 Windows Vista 的用户帐户控制
http://msdn.microsoft.com/zh-cn/magazine/cc163486.aspx
- 解决安装程序在win7/vista安装时出现2869的错误
- Win7/Vista下安装SQL Server 2005/2008后,进行附加数据库错误的解决
- Inno Setup打包的安装程序在Vista/Win7上自动提示需要管理员权限的方法
- Inno Setup打包的安装程序在Vista/Win7上自动提示需要管理员权限的方法
- 安装GenyMotion时出现的错误解决
- 解决安装ubuntu时,出现安装程序向硬盘复制文件时遇到的错误
- 在安装office2003时,出现"安装程序包的语言不受系统支持"的错误,如何解决?
- 在win7 64上用npm安装phantomjs时出现Error: UNABLE_TO_VERIFY_LEAF_SIGNATURE错误的解决方法。
- 解决在centos x64 上安装openfire出现的错误
- VIM在安装完YCM之后出现错误的解决
- win7下安装SQLServer2005_SSMSEE时出现29506错误的解决方案
- iMindMap8在安装时出现1018错误怎么解决
- win7 安装oracle10g 出现兼容性错误--程序异常终止
- 解决安装软件出现错误Error 1935安装程序集
- 解决win7下安装SQL2000时【以前的某个程序安装已在安装计算机上创建挂起的文件操作。运行安装程序之前必须重新启动计算机!】
- 解决vista/win7安装windows live messenger 2011找不到wlidcli.dll及错误800488eb
- 解决 Win7 64位安装Oracle11g时出现的 [INS-20802] Oracle Net Configuration Assistant failed 错误
- 解决vista安装msi文件错误(2869)问题
- 翻译 EHCI SPCE 4 CHAP
- SSIS(SQL Server Integration Service)处理导入数据时, 存在的更新, 不存在的插入
- 2010 年 Web 设计风 (下)
- 小技巧-div上有连接效果
- 扩展DynamicMapServiceLayer和TiledMapServiceLayer,实现访问wms数据和自定义切图数据
- 解决安装程序在win7/vista安装时出现2869的错误
- 通过进程名获取进程PID
- 对象坐标方法
- 在HP-UX中设置DNS客户端
- (转)sqlite3语法
- Window CE 6.0 USB Driver implemention
- 在 catch 块内进行 throw 的多种方式
- Java中各类Cache机制实现解决方案
- (转)Android Content Provider的应用