如何将程序添加到VS2022安装程序项目中的用户程序菜单?
如何使用Visual Studio 2022设置项目将程序添加到目标用户的程序菜单中?无论如何,这都是很棒的。
How do I add a program to my target user's program menu using Visual Studio 2022 setup project? Any way to do it would be great.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
假设您需要与安装程序软件包一部分的程序进行快捷键(最有可能在“应用程序文件夹”中),则可以使用以下步骤:
打开安装程序项目的“文件系统”视图(右) - 单击“解决方案资源管理器”中的项目,然后从“弹出菜单”中选择“视图 - > file System”命令)。
在该视图的左侧窗格中选择“用户的程序菜单”,然后右键单击右侧窗格的任何地方;然后,您应该查看带有“创建新快捷方式”命令的弹出菜单(类似于如下所示)
要为快捷方式添加图标,请在右侧窗格中选择该新项目,然后在“属性”窗口中选择“ browse”属性。您可以在目标文件系统中浏览图标 - 但请注意,默认情况下,仅显示“*.ICO”文件;如果要查找目标程序并使用该文件的默认值(即最低ID号)图标,则需要在弹出对话框中选择“所有文件”或“可执行文件”。
Assuming you want a shortcut to a program that is part of the installer package (most likely in the "Application Folder"), then you can use the following steps:
Open the "File System" view for your installer project (right-click on the project in Solution Explorer and select the "View -> File System" command from the pop-up menu).
Select the "User's Programs Menu" in the left-hand pane of that view, then right-click anywhere in the right-hand pane; you should then see a pop-up menu with a "Create New Shortcut" command (similar to that shown below)
To add an icon for the shortcut, select that new item in the right-hand pane and then, in the "Properties" window, select "Browse" from the "Icon" property. You can browse for an icon in the target file system – but note that, by default, only "*.ico" files are shown; you need to select "All Files" or "Executable Files" in the pop-up dialog if you want to find the target program and use that file's default (i.e. lowest ID number) icon.