安装程序在桌面上创建 2 个快捷方式:文件 (FS) 和 Internet 快捷方式 (IS)。卸载时FS
删除正常,但IS
仍然存在。然后我评论FS
和测试。现在它已成功创建和删除。
怎么了?
<Directory Id='TARGETDIR' Name='SourceDir'>
<Directory Id="DesktopFolder" Name="Desktop"/>
<Directory Id="ProgramMenuFolder" Name="PMenu">
<Directory Id="ProgramMenuDir" Name="Advertised Shortcut" />
</Directory>
</Directory>
<DirectoryRef Id="DesktopFolder">
<Component Id="ApplicationShortcutConf" Guid="{9FF60FF5-F1A2-413F-98FB-CF7B3101F10F}">
<Shortcut Id="CompanyUtilConfigurator1"
Directory="DesktopFolder"
Advertise="no"
Name="Company Util Configurator"
WorkingDirectory="INSTALLDIR"
Icon="CompanyUtilConfiguratorIcon.exe">
</Shortcut>
<RegistryValue Root="HKCU" Key="Software\Company LLC\Company\Util" Name="installed_conf" Type="integer" Value="1" KeyPath="yes"/>
<RemoveFolder Id="DeleteShortcutFolder1"
Directory="DesktopFolder"
On="uninstall" />
</Component>
<Component Id="ApplicationShortcut" Guid="{77C005A8-63DC-43F1-9081-84157EDED0B3}">
<Condition><![CDATA[WS_SHORTCUT_NAME<>""]]></Condition>
<util:InternetShortcut
Id="Home"
Directory="DesktopFolder"
Name="Company Util" Type="url"
Target="[WS_SHORTCUT_NAME]"/>
<RemoveFolder Id="DesktopFolder2" Directory="DesktopFolder" On="uninstall"/>
<RegistryValue Root="HKCU" Key="Software\Company LLC\Company\Util" Name="installed" Type="integer" Value="1" KeyPath="yes"/>
</Component>
</DirectoryRef>