Support for ComponentGroup

Mar 21, 2015 at 4:43 PM
Does WixSharp suppport ComponentGroups en ComponentRef? How?
Mar 22, 2015 at 12:39 PM
No Wix# doesn't directly support ComponentGroups.

In fact Wix# philosophy is to hide any aspect of Component. The reason is that a Component is an entity that has no place in the modern deployment requirement and rather an MSI legacy concept (as many others). But of course many woud argue with me about this :)

Anyway, of course Components and ComponentRefs are generated but they are completely hidden and with Wix# you never define components in C# code at all. While you can still fully control ComponentGroups via XML injection but quite possibly raw WiX may be a better choice for you.
Apr 16, 2015 at 1:23 PM
Can we please know how to implement IIS / Website throught WIX#..
Apr 16, 2015 at 1:25 PM
Have a look at <Wix# Samples>\IIS
Apr 20, 2015 at 5:14 PM
Can we make it happen without VIRTUALDIR
Apr 21, 2015 at 1:45 AM
Edited Jun 18, 2015 at 1:21 AM
The sample I referred to does not use VIRTUALDIR. What exactly seems to be a problem?
Apr 21, 2015 at 6:00 AM
This is the code im using.
          Dirs = new[]
            {
                new Dir(new Id("IIS_WEBSITEPHYSICALPATH"), @"%ProgramFiles%\" + productName + "_" +productVersion +"_Web",
                    new Files(@"..\OutFiles\WebPublish\*.*"),
                    new File(System.IO.Path.GetFullPath("License.rtf"),
                        new IISVirtualDir
                        {
                            Name = productName + "_Web_VDIR",
                            WebSite = new WebSite(productName + "_Website") { 
                                InstallWebSite = true,
                                Description = "[IIS_WEBSITENAME]",
                                Addresses = new []{
                                    new WebSite.WebAddress(){
                                        Attributes = new Attributes() { 
                                            { "IP", "[IIS_WEBSITEIPADDRESS]" }, 
                                            { "Port", "[IIS_WEBSITEPORT]" } 
                                        }  
                                    } 
                                }
                            },
                            WebAppPool = new WebAppPool("[IIS_POOL_NAME]"),
                        })
                ),
                new Dir(new Id("ILOGICEXEC_PHYSICALPATH"), @"%Desktop%\" + productName + "_" +productVersion + "_ILogic",
                      new Files(@"..\OutFiles\AppPublish\*.*")
                )
            },

It seems to create a virtual dir with the name { productName + "_Web_VDIR" }

Please have a check.
Apr 21, 2015 at 11:58 AM
Yes this is what I would expect. I see that you set Name = productName + "_Web_VDIR" so it becomes the ID and Alias of that value. Thus it emits the following XML (for ProductName="Test"):
<WebVirtualDir Id="Test_Web_VDIR" Alias="Test_Web_VDIR" Directory="IIS_WEBSITEPHYSICALPATH" WebSite="Test_Website" xmlns="http://schemas.microsoft.com/wix/IIsExtension">
    <WebApplication Id="MyWebAppWebApplication" Name="MyWebApp" WebAppPool="Test_Web_VDIR_AppPool" />
</WebVirtualDir>
Seems OK to me. Am I missing something?
Jun 17, 2015 at 1:26 PM
Edited Jun 17, 2015 at 1:27 PM
How to implement Secure in WebAddress?
              Dirs = new[] {
                new Dir(new Id("IIS_WEBSITEPHYSICALPATH"), @"%ProgramFiles%\" + productName + "_" +productVersion,
                    new Dir("Web",
                        new Files(@"..\OutFiles\WebPublish\*.*"),
                        new File(System.IO.Path.GetFullPath("License.rtf"),
                            new IISVirtualDir
                            {
                                Name = productName + "_Web_VDIR",
                                AppName = "MyApp",
                                WebSite = new WebSite(productName + "_Website") {
                                    AttributesDefinition = "ConfigureIfExists=no",
                                    Attributes = new Attributes() { 
                                                { "Description", "[IIS_WEBSITENAME]" }
                                    },
                                    InstallWebSite = true,
                                    Addresses = new []{
                                        new WebSite.WebAddress(){
                                            Attributes = new Attributes() { 
                                                { "IP", "[IIS_WEBSITEIPADDRESS]" }, 
                                                { "Port", "[IIS_WEBSITEPORT]" },
                                                { "Secure", "[IIS_WEBSITEPROTOCOL]"}
                                            }  
                                        } 
                                    },
                                }
                            }
                        )
                    ),
                    new Dir("Logic",
                            new Files(@"..\OutFiles\AppPublish\*.*")
                    )
                ),
            },
I'm getting error:

Error 322 The WebAddress/@Secure attribute's value, '[IIS_WEBSITEPROTOCOL]', is not a legal yes/no value. The only legal values are 'no' and 'yes'.

Can u please help me with a small example to choose http/https from combobox to publish the website
Jun 18, 2015 at 1:21 AM
This WiX error is saying you that Secure attribute can be set only to the yes/no value while you are trying to set it to the property value. Wix may not like it in two cases:
  • This property does not exist
  • MSI does not allow this attribute to be set from property.