Top "Xmlreader" questions

xmlreader - Represents a reader that provides fast, noncached, forward-only access to XML data.

How to read from an XmlReader without moving it forwards?

I got this scenario: while (reader.Read()) { if (reader.NodeType == XmlNodeType.Element && reader.Name == itemElementName) { XElement item = null; …

c# .net xml xml-parsing xmlreader
XmlReader breaks on UTF-8 BOM

I have the following XML Parsing code in my application: public static XElement Parse(string xml, string xsdFilename) { var readerSettings = …

c# utf-8 xmlreader byte-order-mark
How to read an xml file directly to get an XElement value?

Right now I am using: XElement xe = XElement.ReadFrom which requires an XmlReader: XmlReader reader = XmlTextReader.Create which requires a …

c# .net xmlreader xelement
Current line number from a System.Xml.XmlReader (C# & .Net)

Does anyone know how I can get the current line number of an System.Xml.XmlReader? I am trying to …

c# .net xml xmlreader line-numbers
XmlException while parsing xml with encoding specified as "utf-16"

I have an issue with parsing XML which has utf-16 encoding but it works perfectly fine with utf-8. Can any …

c# asp.net .net xml-parsing xmlreader
How to best detect encoding in XML file?

To load XML files with arbitrary encoding I have the following code: Encoding encoding; using (var reader = new XmlTextReader(filepath)) { …

encoding linq-to-xml xmlreader xelement
Parsing an XML stream with no root element

I need to parse a continuous stream of well-formed XML elements, to which I am only given an already constructed …

java xml sax xmlreader
getting the current position from an XmlReader

Is there a way to get the current position in the stream of the node under examination by the XmlReader? …

.net xmlreader
Why is FileStream not closed by XmlReader

So I am using the FileStream inside XmlReader using (XmlReader reader = XmlReader.Create(new FileStream(archivePath, FileMode.Open), readerSettings)) { reader.…

c# .net idisposable xmlreader
Parse XML with PHP and XMLReader

I've been trying to parse a very large XML file with PHP and XMLReader, but can't seem to get the …

php xml xmlreader