In another thread last week, I tried to extend util:User by adding an
attribute.  I eventually determined in the code that adding an attribute is
not allowed for this element.  So I assumed that I could add a child
element, but also does not work.  UtilCompiler.cs has the following code

            foreach (XmlNode child in node.ChildNodes)
            {
                if (XmlNodeType.Element == child.NodeType)
                {
                    if (child.NamespaceURI == this.schema.TargetNamespace)
                    {
                        SourceLineNumberCollection childSourceLineNumbers =
Preprocessor.GetSourceLineNumbers(child);
                        switch (child.LocalName)
                        {
                            case "GroupRef":
                                if (null == componentId)
                                {
this.Core.OnMessage(UtilErrors.IllegalElementWithoutComponent(childSourceLineNumbers,
child.Name));
                                }
                                this.ParseGroupRefElement(child, id);
                                break;
                            default:
                                this.Core.UnexpectedElement(node, child);
                                break;
                        }
                    }
                    else
                    {
                        this.Core.UnsupportedExtensionElement(node, child);
                    }
                }
            }

I previously wrote a CompilerExtension which added a child element to the
Component element.  I see that it does not have the
this.Core.UnsupportedExtensionElement(node, child);

I want to extend the behavior of the util:User element to hide the service
account from the logon screen.  If I am going at this the wrong way, what is
the correct approach?

Also in Compiler.cs I noticed the following comments at the end of parsing
the Component element:
                        // CompilerExtension must return a key path type, so
the component key path is either set or not (no automatic selection).
In searching the wix code I notice that only the DependencyCompiler and hte
UtilCompiler (only when parsing the Source attribute) sets the
ComponentKeypathType, so I assume that the case is overstated in the
comment.






--
View this message in context: 
http://windows-installer-xml-wix-toolset.687559.n2.nabble.com/CompilerExtension-extending-util-User-tp7599005.html
Sent from the wix-users mailing list archive at Nabble.com.

------------------------------------------------------------------------------
Dive into the World of Parallel Programming. The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to