Deployment 如何使用WiX 3.0部署注册表项和值?
如果我想创建注册表项 HKEY\U LOCAL\U MACHINE\SYSTEM\CurrentControlSet\Services\Eventlog\Application\MyApp 使用字符串值 EventMessageFile:C:\Path\To\File.dllDeployment 如何使用WiX 3.0部署注册表项和值?,deployment,wix,windows-installer,Deployment,Wix,Windows Installer,如果我想创建注册表项 HKEY\U LOCAL\U MACHINE\SYSTEM\CurrentControlSet\Services\Eventlog\Application\MyApp 使用字符串值 EventMessageFile:C:\Path\To\File.dll 如何在我的3.0 WXS文件中定义它?XML应该是什么样的示例非常受欢迎。请在DirectoryRef-->目录下使用以下内容。。。 退房。例如: <registry action="write" root"H
如何在我的3.0 WXS文件中定义它?XML应该是什么样的示例非常受欢迎。请在DirectoryRef-->目录下使用以下内容。。。 退房。例如:
<registry action="write"
root"HKLM" key="SYSTEM\CurrentControlSet\Services\Eventlog\Application\MyApp"
type="string" value="EventMessageFile : C:\Path\To\File.dll" />
我选择了这个:
<Component Id="EventLogRegKeys" Guid="{my guid}">
<RegistryKey Id="Registry_EventLog" Root="HKLM" Key="SYSTEM\CurrentControlSet\Services\Eventlog\Application\MyApp" Action="create">
<RegistryValue Id="Registry_EventLog_EventSourceDll" Action="write" KeyPath="yes" Name="EventMessageFile" Type="string" Value="C:\Path\To\File.dll" />
</RegistryKey>
</Component>
最好使用文件引用语法引用File.dll,以确保使用安装它的实际路径。使用[#filekey]
,其中filekey
是描述文件的文件元素的Id
。您似乎想要创建一个事件日志源。如果是这种情况,您应该查看util扩展中的元素