我希望你们今天过的特别好,身体健康!我只需要Wix安装程序中的一些帮助。我有一个使用WIX创建的.msi安装程序。安装程序还会安装一些Windows服务。安装.msi后,服务将安装并在之后正常运行。但是,在卸载/删除.msi文件时,不会删除服务。以下是我正在使用的代码,如果我的代码有任何错误,请纠正我:
<Directory Id="serviceencrypt" Name="service-encryption">
<Component Id="MyAppEncryption">
<File
Id="MyAppEncryptionEXE"
Name="MyApp.Encryption.exe"
DiskId="1"
Source="$(var.MyAppInstallerFiles)\application\service-encryption\MyApp.Encryption.exe"
Vital="yes"
KeyPath="yes" />
<ServiceInstall Id="MyAppEncryptionInstall" Type="ownProcess" Vital="yes"
Name="MyAppEncryption" DisplayName="MyApp Encryption"
Description="MyApp Encryption" Start="auto"
ErrorControl="normal"
Arguments=" action:run" Interactive="no" Account="NT AUTHORITY\LocalService">
</ServiceInstall>
<ServiceControl Id="MyAppEncryptionStartService" Stop="both" Start="install" Remove="uninstall"
Name="MyAppEncryption" Wait="yes" />
</Component>
</Directory>
任何帮助将不胜感激。谢谢!