我有一个将被部署到客户端计算机与Visual Studio 2010的安装项目一个应用程序。 我的应用程序创建一个桌面快捷方式到主exe文件。
如果我打开快捷方式的属性,然后选择更改图标我看到,用于快捷方式的图标是一样的东西:
%SystemRoot%Installer{5B821236-4F7A-4AC9-8BA6-441F456F12F0}_83771230001D45618121E3.exe
Hoever,我想这是
%程序Files% MyCompany的 MyApp的 MyApp.exe的
![巧用visual studio VC 解决pyinstaller打包的exe文件过大的问题 一](https://p.xsw88.cn/allimgs/daicuo/20230906/3474.png)
或
%程序Files% MyCompany的 MyApp的 MyIcon.ico
有没有办法才达到的?
我已经使用JavaScript的PICE会修改我的设置在PostBuild步骤添加
DISABLEADVTSHORTCUTS = 1
在安装文件中的属性表。也许解决方案是相似的,但我不知道什么改变。
解决方案真正的问题似乎只创建低质量(48×48像素最大)图标,在安装项目中的错误,并已被证实由微软,但没有得到解决,直到现在。
请参阅http://connect.microsoft.com/VisualStudio/feedback/details/540424/setup-deployment-project-creates-poor-defaulticon-for-file-type
您可以通过编辑* .msi文件与Orca的解决这个问题:
看那快捷方式
表,找到桌面快捷方式,记得图标_
值。
转至图标表,至极包含entrys的名称和数据列。找到合适的图标,双击 [二进制数据]
输入和浏览您的高分辨率图标。
不幸的是,你必须要做到这一点,每次你重新安装项目,但至少你有一个很好的结果。如果我有一些空闲时间我会尝试的过程自动化和更新这个帖子。
I have a Application that is deployed to client machines with a Visual Studio 2010 Setup Project. My App creates a Desktop Shortcut to the main exe file.
If I open the shortcut's properties and choose "change icon" I see that the icon used for the shortcut is something like:
%SystemRoot%Installer{5B821236-4F7A-4AC9-8BA6-441F456F12F0}_83771230001D45618121E3.exe
Hoever, I want it to be
%Program Files%MyCompanyMyAppMyApp.exe
or
%Program Files%MyCompanyMyAppMyIcon.ico
Is there a way to achive that?
I already use a pice of Javascript that modifies my setup in a PostBuild Step to add
DISABLEADVTSHORTCUTS = 1
to the properties table in the Setup file. Maybe the solution is similar, but I don't know what to change.
解决方案The real issue seems to be a bug in the Setup Project creating only low quality (48x48 px max) icons and has been confirmed by Microsoft but not been fixed until now.
See http://connect.microsoft.com/VisualStudio/feedback/details/540424/setup-deployment-project-creates-poor-defaulticon-for-file-type
You can fix this by editing the *.msi file with Orca:
Look at the Shortcut
Table, find the Desktop Shortcut, remember the Icon_
value.
Go to the Icon Table, wich contains entrys with a Name and a Data column. Locate the right Icon, Double Click the [Binary Data]
entry and browse for your high resolution icon.
Unfortunatly you have to do this everytime you recreate the setup project, but at least you have a good result. If I have some spare time I will try to automate the process and update this post.
相关推荐
最新文章