EDN Admin
Well-known member
hi,all, I am experiencing a problem that when i get the bstr value of an attribute of any xml element node, the value contains space(s) (tailing the actual value) as well, so how to remove those space(s). this is how i get the value:
<pre lang="x-xml <XmlNode1 Content="5/20/1999 "/>[/code]
<div style="color:black; background-color:white
<pre>MSXML2::IXMLDOMNamedNodeMapPtr DOMNamedNodeMapPtr1;
MSXML2::IXMLDOMNodePtr DOMNodePtr1;
_variant_t varAtt1;
DOMNamedNodeMapPtr1 = pNode1 ->attributes;
DOMNodePtr1 = DOMNamedNodeMapPtr1 ->getNamedItem(L<span style="color:#a31515 "att");
DOMNodePtr1 ->get_nodeValue(&varAtt1);[/code]
cheers
daiyue
<br/>
View the full article
<pre lang="x-xml <XmlNode1 Content="5/20/1999 "/>[/code]
<div style="color:black; background-color:white
<pre>MSXML2::IXMLDOMNamedNodeMapPtr DOMNamedNodeMapPtr1;
MSXML2::IXMLDOMNodePtr DOMNodePtr1;
_variant_t varAtt1;
DOMNamedNodeMapPtr1 = pNode1 ->attributes;
DOMNodePtr1 = DOMNamedNodeMapPtr1 ->getNamedItem(L<span style="color:#a31515 "att");
DOMNodePtr1 ->get_nodeValue(&varAtt1);[/code]
cheers
daiyue
<br/>
View the full article