Closed Germs2004 closed 2 weeks ago
WixSharp actually supports specifying WiX attributes that are not directly mapped to the WixSharp entities properties. Thus you can easily achieve the desired result by using a generic property AtributesDefinition
:
Note, this attribute is only available in WiX5 (not WiX4) so if you do not have it installed globally you might need to do it from the code for your specific project:
WixTools.SetWixVersion(Environment.CurrentDirectory, "5.0.0");
var project = new Project("MyProduct", . . .
But I added the dedicated property so it will be available in the very next release.
Excellent, thank you for the perfect workaround and for adding the new property. AttributesDefinition worked perfectly. (and thanks for WixSharp, because Wix is terribly difficult without it)
Please add a feature to WixSharp that allows us to specify the "Group" name when adding a new FirewallException rule. It appears that WixToolkit has a property named "Grouping" for this, though I haven't tested it.
I suggest adding a new "Group" property that works like this:
screenshot of the Windows Firewall table showing the Group column that I'd like to be able to edit:
As a workaround, I think the only way to do this currently is to not use the FirewallException object, but call a Powershell script instead, which supports specifying the Group. Here is a Powershell command for that:
New-NetFirewallRule -DisplayName "Contoso Web Server" -Direction Inbound -Program "C:\Contoso\webserver.exe" -Action Allow -Group "Contoso"