How to change standalone="no" to "Yes" in XML Port

yukonyukon Member Posts: 361
Dear Team,

I want to set "standalone=no" to "standalone=yes". How to change this parameter in XMLPort.

eg. <?xml version="1.0" encoding="UTF-8" standalone="no"?>
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>

Please guide to me.

Regards,
Yukon
Make Simple & Easy

Comments

  • nayenaye Member Posts: 4
    VAR      
          XMLDom@1210017 : Automation 'Microsoft XML, v6.0'.DOMDocument60";
          XMLCurrNode@1210016 : Automation 'Microsoft XML, v6.0'.IXMLDOMNode";
          XMLPI@1210034 : Automation 'Microsoft XML, v6.0'.IXMLDOMProcessingInstruction";
          XMLAttr@1210035 : Automation 'Microsoft XML, v6.0'.IXMLDOMNamedNodeMap";
          fFile@1210030 : File;
          oStream@1210004 : OutStream;
          iStream@1210005 : InStream;
        BEGIN
    
            fFile.CREATE( 'FilePath + FileName' );
            fFile.CREATEOUTSTREAM( oStream );
            XMLPORT.EXPORT(50000, oStream, Rec);
            fFile.CREATEINSTREAM( iStream );
            CREATE( XMLDom );
            XMLDom.load( iStream );
            fFile.CLOSE;      
            XMLPI := XMLDom.firstChild;
            XMLAttr := XMLPI.attributes;        
            XMLCurrNode := XMLAttr.getNamedItem('standalone');
            XMLCurrNode.text := 'yes';
    	// or you can remove XMLAttr.removeNamedItem('standalone');
            XMLDom.save( 'FilePath + FileName' );
            CLEAR( XMLDom );
    
Sign In or Register to comment.