DocumentSet.AddDocument Method (IXPathNavigable)DocumentSet.AddDocument Method (IXPathNavigable)DocumentSet::AddDocument Method (IXPathNavigable^)

Adds the document represented by the specified IXPathNavigableIXPathNavigableIXPathNavigable to the set of available documents, and associates it with its document URI.

Syntax

Public Function AddDocument( _
    navigable As System.Xml.XPath.IXPathNavigable _
) As Boolean
public bool AddDocument(
    System.Xml.XPath.IXPathNavigable navigable
)
public:
bool AddDocument(
    System.Xml.XPath::IXPathNavigable^ navigable
)
 

Return Value

Type: System.BooleanSystem.BooleanSystem::Boolean

trueTruetrue if the document was added to the DocumentSetDocumentSetDocumentSet; falseFalsefalse otherwise.

Exceptions

ExceptionCondition
ArgumentNullExceptionArgumentNullExceptionArgumentNullException navigable is null a null reference (Nothing in Visual Basic) nullptr.
ArgumentExceptionArgumentExceptionArgumentException
  • navigable is not a document node.
  • The document uses the wrong name table.
  • The document URI of navigable is not a valid lexical value for xs:anyURI.
  • The document URI of navigable is not absolute.

Remarks

If the document containing navigable has an empty document URI then no change is made.