Author Topic: genxml error - Data at the root level is invalid Line 1, position 1  (Read 5459 times)

0 Members and 2 Guests are viewing this topic.

gwilson

  • Jr. Member
  • **
  • Posts: 2
  • Karma: 0
    • View Profile

First, much kudos on a great piece of software.  I am able to perform some of the basic commands in XBMC. I am having an issue though trying to GenXML for my movies.  I am running Windows 7 64 bit. XBMC is Dharma RC2.  VoxCommando is 0.851.   I am running both programs as administrator and have XBMC already running when starting VoxCommando.  Attempting to GenXML throws the following error.

************** Exception Text **************
System.Xml.XmlException: Data at the root level is invalid. Line 1, position 1.
   at System.Xml.XmlTextReaderImpl.Throw(Exception e)
   at System.Xml.XmlTextReaderImpl.Throw(String res, String arg)
   at System.Xml.XmlTextReaderImpl.ParseRootLevelWhitespace()
   at System.Xml.XmlTextReaderImpl.ParseDocumentContent()
   at System.Xml.XmlTextReaderImpl.Read()
   at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace)
   at System.Xml.XmlDocument.Load(XmlReader reader)
   at System.Xml.XmlDocument.LoadXml(String xml)
   at VoxCommando.xbmcToXML.makeMovieXML(String strQuery, VoxOptions myVoxOptions)
   at VoxCommando.GenXML.btnXBMCmovies_Click(Object sender, EventArgs e)
   at System.Windows.Forms.Control.OnClick(EventArgs e)
   at System.Windows.Forms.Button.OnClick(EventArgs e)
   at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
   at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ButtonBase.WndProc(Message& m)
   at System.Windows.Forms.Button.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


************** Loaded Assemblies **************
mscorlib
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.4952 (win7RTMGDR.050727-4900)
    CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
----------------------------------------
VoxCommando
    Assembly Version: 0.8.5.1
    Win32 Version: 0.8.5.1
    CodeBase: file:///C:/Users/Theater/VoxCommando/VoxCommando.exe
----------------------------------------
System.Windows.Forms
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Windows.Forms/2.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
System
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Drawing
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Drawing/2.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
Interop.SpeechLib
    Assembly Version: 5.4.0.0
    Win32 Version: 5.4.0.0
    CodeBase: file:///C:/Users/Theater/VoxCommando/Interop.SpeechLib.DLL
----------------------------------------
CoreAudioApi
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.0.0
    CodeBase: file:///C:/Users/Theater/VoxCommando/CoreAudioApi.DLL
----------------------------------------
System.Speech
    Assembly Version: 3.0.0.0
    Win32 Version: 3.0.6920.1109 (lh_tools_devdiv_wpf.071009-1109)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Speech/3.0.0.0__31bf3856ad364e35/System.Speech.dll
----------------------------------------
System.Xml
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Xml/2.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
Interop.iTunesLib
    Assembly Version: 1.13.0.0
    Win32 Version: 1.13.0.0
    CodeBase: file:///C:/Users/Theater/VoxCommando/Interop.iTunesLib.DLL
----------------------------------------
System.Configuration
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Configuration/2.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
----------------------------------------
Accessibility
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.4927 (NetFXspW7.050727-4900)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/Accessibility/2.0.0.0__b03f5f7f11d50a3a/Accessibility.dll
----------------------------------------


Any Ideas ?

Thanks.

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7714
  • Karma: 116
    • View Profile
    • VoxCommando
Re: genxml error - Data at the root level is invalid Line 1, position 1
« Reply #1 on: December 23, 2010, 09:27:40 PM »
The error message unfortunately doesn't really tell me exactly what I need to know, but I think VC is failing to connect to xbmc.  Can you be more specific about which "basic" commands are working?

Some basic commands like moving and scrolling, use keyboard emulation and should work no matter what.  Other commands like "Browse Movies" require a proper connection to xbmc and if they work then GenXML should work too.

Also, do you get this error for every XBMC button on GenXML?  If you are clicking "Generate all", try instead to click them one at a time "Artists" "Albums" etc.  If none of them work then your connection settings are probably wrong, or there may be a problem with your XBMC database.  If most of them work, then we can try to narrow down what is causing some of them to fail.

EDIT: I just re-read your post and noticed that you said it failed on Movies, but my question still stands.  Does it fail only on Movies and work on the other buttons like Artist?  If it only fails on Movies, then you either have a problem with your movie database (like it is empty or corrupt somehow) or there is a character in there that is not expected that is either screwing up the html transmission from XBMC to VC, or screwing up the xml creation.  If that is the case I can probably make a change that will fix it, once we figure out who the culprit is.
« Last Edit: December 23, 2010, 09:33:12 PM by jitterjames »

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7714
  • Karma: 116
    • View Profile
    • VoxCommando
Re: genxml error - Data at the root level is invalid Line 1, position 1
« Reply #2 on: December 23, 2010, 10:27:25 PM »
I just did a test, when xbmc was not running (in other words not connectable) and I got 0 on all the buttons, except on Movies, which threw an error that looked like yours.

This means two things to me.

1 - you probably aren't connecting to xbmc properly, so:  One of your settings is wrong, or there is a network problem.
2 - I need to add some error checking to my movie generating code...  :bonk

I should probably also generate a specific message if VC is unable to connect to xbmc.  :-[

gwilson

  • Jr. Member
  • **
  • Posts: 2
  • Karma: 0
    • View Profile
Re: genxml error - Data at the root level is invalid Line 1, position 1
« Reply #3 on: December 24, 2010, 09:15:54 PM »
Thanks for the quick reply.  You were right on the money.  I apparently wasn't connecting to XBMC.   I had the port set to 8080.  I didn't want to use the HTTP default because I have a webserver running on another system on my network.  I set the port to the default (80) and all is well.  Now that I've got it working, I intend to donate but it won't be until early February when my next allotment arrives.  Thanks again.

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7714
  • Karma: 116
    • View Profile
    • VoxCommando
Re: genxml error - Data at the root level is invalid Line 1, position 1
« Reply #4 on: December 25, 2010, 08:34:34 AM »
Weird.  I use port 8080, and I know that some people have had problems trying to use port 80.

Whatever works works, but are you sure you had the port set to 8080 on both VC and XBMC?