This is possible, in fact it's even pretty easy.
Create a StringWriter that writes to a stringbuilder, or a stream based on a
memory stream. Pass either of these to the XmlTextWriter, perform your
operations, then pull your string out of the stringbuilder or the memory
stream.
It's about 3 lines of code, total...
--
Chris Mullins, MCSD.Net, MCPD:Enterprise
http://www.coversant.net/blogs/cmullins
"Rob" <ro***@yahoo.comwrote in message
news:y8******************************@comcast.com. ..
>I would like to store the contents of the xml created via the XmlTextWriter
to a string as opposed to a file. Is this possible ? If so how ? Is this
the best way to create xml that gets stored to a variable? Am I better off
using the xmldom ?