• Shashank Runthala
  • NEWBIE
  • 0 Points
  • Member since 2020

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 1
    Replies

Hi,

 

I'm just using the XMLStreamWriter to generate an XML String which I am then passing to a web service. I need to generate a string that starts:

 

 

<?xml version="1.0" standalone="no"?>
<!DOCTYPE PRICEREQUEST SYSTEM  \'http://164.39.41.88:81/PriceCheckerDTD1.0/PriceRequestIN.dtd\'>

So far I have:

 

 

XmlStreamWriter w = new XmlStreamWriter();
w.writeStartDocument(null, '1.0');

But I can't see anyway of adding the standalone attribute to the document start or the DOCTYPE tag to the next line.

 

Does anyone know how this can be achieved using the XMLStreamWriter?

 

Cheers

 

James