parent Attribute

Microsoft Office InfoPath

Show All Show All

parent Attribute

Specifies a relative XPath expression from the container node.

Type

      xsd:string
    

Remarks

The parent attribute is an optional attribute of the chooseFragment element.

Refers to the XML Document Object Model (DOM) node under which this fragment should be inserted. The default value is ".", which corresponds to inserting directly under the container parent node.

Example

The following is an example of the parent attribute as it is used in the chooseFragment element:

    <xsf:editing>
   <xsf:xmlToEdit name="CD_10"
      item="/CustomUISample/CDCollection/CD" 
      container="/CustomUISample">
      <xsf:editWith caption="CD"
         xd:autogeneration="template" 
         component="xCollection">
         <xsf:fragmentToInsert>
            <xsf:chooseFragment parent="CDCollection"
               followingSiblings=".">
               <CD>
                  <Title></Title>
                  <Artist></Artist>
                  <Tracks>
                     <Track></Track>
                     <Track></Track>
                  </Tracks>
               </CD>
            </xsf:chooseFragment>
         </xsf:fragmentToInsert>
      </xsf:editWith>
   </xsf:xmlToEdit>
</xsf:editing>