安装程序完成安装后自动启动时,应用程序中的 COM DLL 异常!

发布于 2024-10-07 09:31:29 字数 313 浏览 0 评论 0原文

我正在使用 解决方案来修改 MSI 以包含一个供用户决定的复选框他/她是否想在安装程序退出后启动应用程序。

尽管一切工作正常,但我注意到应用程序在自动启动时无法使用在安装过程中注册的任何 COM DLL。从开始菜单再次启动时,该应用程序可以完美运行。

我已经在 Windows XP 和 Windows 7 上对其进行了测试。COM

DLL 已在安装项目中被标记为自注册 DLL。

I'm using this solution to modify the MSI to include a checkbox for user to decide whether s/he wants to launch the application after setup exits.

Although everything works just fine, what I noticed was the application was not able to use any COM DLL's registered during the setup when it was auto launched. The app works perfectly when launched again from start menu.

I have tested it on Windows XP and Windows 7.

The COM DLL's have been marked as self registering dll's in the setup project.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

扬花落满肩 2024-10-14 09:31:29

我成功了。问题是没有指定目标目录。此问题中提到了错误修复。

我将脚本中的一行更改为:

sql = "INSERT INTO `CustomAction` (`Action`, `Type`, `Source`, `Target`) VALUES ('VSDCA_Launch', '226', 'TARGETDIR', '[TARGETDIR]\\" + filename + " " + arguments + "')"; 

I got it work. The problem was that the target directory was not specified. The bug fix was mentioned in this question.

I changed one of the lines in script to:

sql = "INSERT INTO `CustomAction` (`Action`, `Type`, `Source`, `Target`) VALUES ('VSDCA_Launch', '226', 'TARGETDIR', '[TARGETDIR]\\" + filename + " " + arguments + "')"; 
岛徒 2024-10-14 09:31:29

很难回答这样一个具体的问题,因为我在测试实验室中没有您的安装程序和应用程序来进行一些基本的分析和故障排除。不过,我会抛出一个想法,看看它是否坚持:

快捷方式和从安装程序创建进程之间的工作目录是否不同?根据 COM 的注册方式,这可能会产生影响。

It's hard to give an answer to such a specific question since I don't have your installer and application in a test lab to do some basic profiling and troubleshooting. However I will throw an idea at the wall and see if it sticks:

Is your working directory different between the shortcut and creating the process from the installer? Depending on how your COM was registered, this can make a difference.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文