I\'m trying to get my httphandler to print out an XML file with the format:
...
[XmlRoot(...)]
only affects the outermost element (
). I suspect you want [XmlElement(...)]
. Of course, another way is to write an object wrapper:
[XmlRoot("SheduledShows")]
public class Shows {
[XmlElement("SheduledShowElement")]
public List Shows {get;set;}
}
And serialize this wrapper object instead of just a list.