Home > Back-end >  Use Txmldocument component errors in the thread class
Use Txmldocument component errors in the thread class

Time:10-22

TempXml:=TXMLDocument. Create (nil);
TempXml. Active:=false;
TempXml. XML. Text:=strXml;
TempXml. Active:=true;
TempXml. Version:='1.0';
TempXml. Encoding:='gb2312'; When run to here, is always wrong, where is set wrong? Please help to have a look at it,
TempXml. SaveToFile (ExtractFilePath (paramstr (0)) + sNewOrdrTBTyp + 'XML');
Try
XMLNode1:=TempXml. DocumentElement;
If XMLNode1. NodeName & lt;> 'trades_sold_get_response then exit;
Try
XMLNode1:=TempXml..childnodes. Nodes [' trades_sold_get_response];
Except,
end;

CodePudding user response:

Urgent urgent!!!!!!

CodePudding user response:

TempXml. Encoding:='gb2312'; When run to here, is always wrong, where is set wrong? Please help to have a look at it,

This kind of writing I also an error in the DELPHI7,
My solution is:
TempXml. Encoding:='gb2312 - delete

TempXml. XML. Text:=AnsiToUtf8 (strXml);
  • Related