VSDCA​​_Launch 在自定义操作脚本中的含义是什么

发布于 2024-09-14 13:07:41 字数 989 浏览 2 评论 0原文

我想在安装后使用 Visual Studio 设置和部署输出启动应用程序。我跟随 文章“如何在 Visual Studio 安装项目中安装后启动应用程序'。 它有一个解决方案,使用自定义操作添加复选框并在安装后启动应用程序。但我仍然有一个问题,应用程序已启动,工作目录与目标目录不同。因此它无法读取 XML 配置文件。我在 自定义操作类型中阅读了有关自定义操作的更多信息 并认为我应该使用操作 34 或 35,但我仍然困惑如何使用。

脚本中原始的插入操作语句是: sql = "INSERT INTO CustomAction (操作, 类型, , 目标) VALUES ('VSDCA​​_Launch', '210', '" + fileId + "', '')";

我知道 210 是 18 + 192,但不知道 VSDCA​​_Launch 是什么意思。如何使用目标目录启动应用程序。谢谢。

编辑

我已更改为 226 = 34 + 192 并且工作正常。

sql = "INSERT INTO CustomAction (操作, 类型, , 目标) VALUES ('VSDCA​​_Launch', '226', 'TARGETDIR', '[TARGETDIR]\App.exe')";

I want to launch an application after installation with Visual Studio setup&deployment output. I follow
the article 'How do I launch an application after install in a Visual Studio Setup Project'.
It has a solution that using Custom Action to add a checkbox and launch the application after installation. But I still have a problem, the application has launched with the working directory was difference from the target directory. Therefore it can't read XML configuration file. I've read more about Custom Action at Custom Action Types and think I should use action 34 or 35 but I'm still confuse how to use.

The original insert action statement in script is:
sql = "INSERT INTO CustomAction (Action, Type, Source, Target) VALUES ('VSDCA_Launch', '210', '" + fileId + "', '')";

I known that 210 is 18 + 192 but don't know what VSDCA_Launch mean. How can I launch the app with target directory. Thank you.

EDIT

I've changed to 226 = 34 + 192 and it work fine.

sql = "INSERT INTO CustomAction (Action, Type, Source, Target) VALUES ('VSDCA_Launch', '226', 'TARGETDIR', '[TARGETDIR]\App.exe')";

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

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

发布评论

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

评论(1

只是一片海 2024-09-21 13:07:41

只是对上述解决方案的一个小修正:
缺少一个反斜杠。我认为这可能与帖子的格式有关。
该行应该是:

sql = "INSERT INTO CustomAction (Action, Type, Source, Target) VALUES ('VSDCA_Launch', '226', 'TARGETDIR', '[TARGETDIR]\\App.exe')";

Just a minor correction to the above solution:
There's a backslash missing. I think it may have to do with the formatting of the post.
The line should be:

sql = "INSERT INTO CustomAction (Action, Type, Source, Target) VALUES ('VSDCA_Launch', '226', 'TARGETDIR', '[TARGETDIR]\\App.exe')";
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文