Formatting raw XML?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • clintonG

    Formatting raw XML?

    I'm using the XmlTextWriter but see no way to format raw XML like this:

    <rss version="2.0" xmlns:cf
    ="http://www.microsoft.c om/schemas/rss/core/2005"
    xmlns:media="ht tp://search.yahoo.co m/mrss"
    xmlns:dc="http://purl.org/dc/elements/1.1/">

    Is it possible to format the raw XML to make it more readable?
    What about some other way to write the XML to the filesystem so it is
    readable in this context?
    I posted to microsoft.publi c.xml but it isn't very active.

  • clintonG

    #2
    Re: Formatting raw XML?

    <snip />

    I've maxed out the use of the .Indentation method and I can't and won't even
    try to argue your sage advice about other methods such as transformation. I
    suppose I'll cope with all of the namespaces displayed on a single line
    compelling a horizontal scroll when wanting to read the raw XML. Thanks for
    your comments...

    Comment

    • Jeroen Mostert

      #3
      Re: Formatting raw XML?

      clintonG wrote:
      I've maxed out the use of the .Indentation method and I can't and won't
      even try to argue your sage advice about other methods such as
      transformation. I suppose I'll cope with all of the namespaces displayed
      on a single line compelling a horizontal scroll when wanting to read the
      raw XML. Thanks for your comments...
      Well, this may sound stupid, but if you simply open the XML file in Internet
      Explorer it will display it without the need for horizontal scrolling. Of
      course, if your XML file is very large IE will probably fail miserably.

      You could also simply use a text editor with word wrapping and syntax
      highlighting. My favorite's TextPad.

      --
      J.

      Comment

      Working...