xsl-list
[Top] [All Lists]

Re: MSXML4 DOM - how get context node attribute value?

2005-04-13 08:01:45
Hardy Merrill wrote:

I'm using MSXML4 DOM in an ASP page - I've pinpointed a specific node in
the document using selectSingleNode, but now I need to get the value of
the "datatype" attribute of that node.  I'm having trouble with the
MSXML4 documentation - can someone tell me how to get the value of an
attribute for the context node?
This is an XSL list; please use it for XSL-specific questions in the future.

The selectNodes and selectSingleNode M$ extensions can only return elements nodes AFAIK, so you'll just have to retreive the target element, cast it to Element if needed by your language and use DOM methods (getAttribute etc) to retreive the attribute value.

Manos

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--



<Prev in Thread] Current Thread [Next in Thread>