BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

XML and Unicode

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> C++ Builder (Students)
View previous topic :: View next topic  
Author Message
bar
Guest





PostPosted: Wed May 16, 2007 2:23 pm    Post subject: XML and Unicode Reply with quote



Hello all.

i am using TXMLDocument in BCB6,
in some of the nodes i have text like

<menu>Ôäí dkjfkdj </menu>

I am not getting the unicode text, the code i am using
NMenuitem->ChildNodes->Nodes[WideString("menu")]->Text;

How can i extract the text

Thanks for the help
SA
Back to top
Remy Lebeau (TeamB)
Guest





PostPosted: Wed May 16, 2007 9:31 pm    Post subject: Re: XML and Unicode Reply with quote



"bar" <shaikakbar250281 (AT) yahoo (DOT) co.in> wrote in message
news:464acd6d (AT) newsgroups (DOT) borland.com...

Quote:
I am not getting the unicode text, the code i am using
NMenuitem->ChildNodes->Nodes[WideString("menu")]->Text;

What exactly are you getting instead?

Quote:
How can i extract the text

What is the Encoding of the Document set to? You will probably have
to decode the Text manually.


Gambit
Back to top
bar
Guest





PostPosted: Wed May 16, 2007 9:57 pm    Post subject: Re: XML and Unicode Reply with quote



Hi remy thanks for reply

i am getting ???? in the place of the unicode characters.

The encoding of the document is
<?xml version="1.0" encoding="Windows-1252" ?>

Thanks
SA
Back to top
Remy Lebeau (TeamB)
Guest





PostPosted: Wed May 16, 2007 11:51 pm    Post subject: Re: XML and Unicode Reply with quote

"bar" <shaikakbar250281 (AT) yahoo (DOT) co.in> wrote in message
news:464b37e0 (AT) newsgroups (DOT) borland.com...

Quote:
i am getting ???? in the place of the unicode characters.

That will happen if you assign a Unicode string to an Ansi string.
Are you assigning the result of the Text property to an AnsiString
variable? The Text property returns a WideString instead.


Gambit
Back to top
bar
Guest





PostPosted: Thu May 17, 2007 8:11 am    Post subject: Re: XML and Unicode Reply with quote

yes.
Even if i did
WideString a = NMenuitem->ChildNodes->Nodes[WideString("title")]->Text;
The result is same.How to resolve this

Thanks
SA
Back to top
bar
Guest





PostPosted: Sun May 20, 2007 3:02 pm    Post subject: Re: XML and Unicode Reply with quote

can anybody help in decoding the text from xml file
Thanks
SA
"bar" <shaikakbar250281 (AT) yahoo (DOT) co.in> wrote in message
news:464c009a (AT) newsgroups (DOT) borland.com...
Quote:
yes.
Even if i did
WideString a = NMenuitem->ChildNodes->Nodes[WideString("title")]->Text;
The result is same.How to resolve this

Thanks
SA
Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> C++ Builder (Students) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.