XmlException parsing


This tool shows great promise! bit rough at this point; here's one bug, I'll be filing a few more.

27 November 2014 build

Tools > XQuery
Type in simple query such as //*
I get:
System.Xml.XmlException: '.', hexadecimal value 0x00, is an invalid character. Line 2, position 1.
   at System.Xml.XmlTextReaderImpl.Throw(String res, String[] args)
   at System.Xml.XmlTextReaderImpl.ParseRootLevelWhitespace()
   at System.Xml.XmlTextReaderImpl.ParseDocumentContent()
   at System.Xml.XPath.XPathDocument.LoadFromReader(XmlReader reader, XmlSpace space)
   at System.Xml.XPath.XPathDocument..ctor(XmlReader reader)
   at XSemmel.XQuery.XQuery.Button_Click(Object sender, RoutedEventArgs e)

Same error message from XPath Query tab in left pane (but no stack trace shown).
Furthermore, any characters cause pink background indicating bad input, even for valid input such as //*

It doesn't seem to matter what the source document is or what the XPath expression is.
Closed Jan 21, 2015 at 4:32 PM by fschnitz
Fixed in release 21-JAN-2015


pht_smendola wrote Jan 15, 2015 at 4:30 PM

New info:

Problem seems to be brought on by opening this XSD:
After that, XPath is broken, even if I replace the XML in the Editor with <foo/>
However, File > New clears up the problem and XPath then works.

And, I realized that I was using Tools > XQuery as if it were XPath, not XQuery, so never mind that part.,

fschnitz wrote Jan 16, 2015 at 7:56 AM

Thank you for reporting this!
I'll look into this at weekend. As a workaround, please remove the XML declaration (first line, "<?xml version="1.0" encoding="utf-8" ?>") and it should work...

fschnitz wrote Jan 21, 2015 at 4:32 PM

Fixed in release 21-JAN-2015