System.Xml.Xsl.XsltArgumentList.AddParam Method

Adds a parameter to the System.Xml.Xsl.XsltArgumentList and associates it with the namespace qualified name.

Syntax

public void AddParam (string name, string namespaceUri, object parameter)

Parameters

name
The name to associate with the parameter.
namespaceUri
The namespace URI to associate with the parameter. To use the default namespace, specify an empty string.
parameter
The parameter value or object to add to the list.

Remarks

The parameter should correspond to a W3C type. The following table shows the W3C types, either XPath or XSLT, and the corresponding.NET class.

String (XPath)

string

Boolean (XPath)

bool

Number (XPath)

double

Result Tree Fragment (XSLT)

System.Xml.XPath.XPathNavigator

Node Set (XPath)

System.Xml.XPath.XPathNodeIterator

XPathNavigator[]

Node* (XPath)

System.Xml.XPath.XPathNavigator

*This is equivalent to a node set that contains a single node.

If the parameter object being invoked from within the style sheet is not one of the above, it is converted according to the following rules:

All other types throw an error.

Requirements

Namespace: System.Xml.Xsl
Assembly: System.Xml (in System.Xml.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0, 4.0.0.0