XmlDoc (XmlNodelist function): Difference between revisions
Jump to navigation
Jump to search
m (1 revision) |
m (1 revision) |
||
Line 7: | Line 7: | ||
<table class="syntaxTable"> | <table class="syntaxTable"> | ||
<tr><th>%doc</th> | <tr><th>%doc</th> | ||
<td>An XmlDoc, which will be set to point to the document associated with <i>nod</i> or <i>nlis</i>. </td></tr> | <td>An <var>XmlDoc</var>, which will be set to point to the document associated with <i>nod</i> or <i>nlis</i>. </td></tr> | ||
<tr><th>nod</th> | <tr><th>nod</th> | ||
<td>An | <td>An <var>Xml</var>Node expression. </td></tr> | ||
<tr><th>nlis</th> | <tr><th>nlis</th> | ||
<td>An | <td>An <var>Xml</var>Nodelist expression.</td></tr> | ||
</table> | </table> | ||
Line 21: | Line 21: | ||
==Examples== | ==Examples== | ||
You can use the XmlDoc function to access the Root node (and then, optionally, to use an XPath expression which is in effect an absolute expression) with an empty <var>xmlNodelist</var>, as in the following example: | You can use the <var>XmlDoc</var> function to access the Root node (and then, optionally, to use an XPath expression which is in effect an absolute expression) with an empty <var>xmlNodelist</var>, as in the following example: | ||
<p class="code">local subroutine (xmlNodelist):display | <p class="code">local subroutine (xmlNodelist):display | ||
Line 35: | Line 35: | ||
===Request-Cancellation Errors=== | ===Request-Cancellation Errors=== | ||
<ul> | <ul> | ||
<li>XmlDoc has no request cancellation errors. | <li><var>XmlDoc</var> has no request cancellation errors. | ||
</ul> | </ul> | ||
==See also== | ==See also== | ||
{{Template:XmlNodelist:XmlDoc footer}} | {{Template:XmlNodelist:XmlDoc footer}} |
Revision as of 17:45, 25 January 2011
Get the XmlDoc associated with this nodelist (XmlNodelist class)
This function returns the xmlDoc associated with the method object.
Syntax
%doc = nodl:XmlDoc
Syntax terms
%doc | An XmlDoc, which will be set to point to the document associated with nod or nlis. |
---|---|
nod | An XmlNode expression. |
nlis | An XmlNodelist expression. |
Usage notes
- The xmlDoc function can be used when it is necessary to get or set xmlDoc properties (such as namespace) given an xmlNodelist.
Examples
You can use the XmlDoc function to access the Root node (and then, optionally, to use an XPath expression which is in effect an absolute expression) with an empty xmlNodelist, as in the following example:
local subroutine (xmlNodelist):display if %this:count eq 0 then
printText Nodelist empty, here is the document: %this:xmlDoc:print
else
...
end if
Request-Cancellation Errors
- XmlDoc has no request cancellation errors.