But don't forget to delete the char* (in this case valueT), as transcode
hands responsibility for that to the caller.
John
> Gary Marsh wrote:
>
> Hi Cad;
>
> Just a guess but I think you probably need to do something
> like this:
>
> DOMString value = newNode.getNodeValue();
>
> char *valueT = value.transcode();
> cout << "VALUE = " << valueT << "\n";
>
> if ( strcmp(valueT,"James T.") == 0 ) {
> cout << "EXECUTING..." << "\n";
> execute_the_action();
> }
>
> good luck;
>
> gary
>
> -----Original Message-----
> From: CAD BILBAO [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, April 10, 2001 1:20 AM
> To: [EMAIL PROTECTED]
> Subject: transcode()
>
> Hi!
>
> Using Apache XML Xerces for C++, with Visual C++ 6.0 on NT.
>
> I am trying to parse a XML doc. I want to display the
> value of a node and execute an action if this value is
> "James T.". I succeed in displaying the value ("James T."),
> but not in executing the action:
>
> ------//------
> DOMString value = newNode.getNodeValue();
>
> char *valueT = value.transcode();
> cout << "VALUE = " << valueT << "\n";
> if (valueT=="James T.") {
> cout << "EXECUTING..." << "\n";
> execute_the_action();
> }
> ------//----
>
> What must I do to compare a 'transcode value' (valueT) with
> a string ("James T.")?
>
> Thanx.
> ___________________________________________________________________________
>
> Tu correo gratuito en HispaVista -
> http://www.hispavista.com/altacorreo/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
--
John Snelson, Software Engineer DecisionSoft Ltd.
Telephone: +44-1865-203192 http://www.decisionsoft.com
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]