Link to home
Start Free TrialLog in
Avatar of hindersaliva
hindersalivaFlag for United Kingdom of Great Britain and Northern Ireland

asked on

Excel 2013 - importing an XML file

I'm trying to import the the attached XML file into Excel 2013. It's a MusicXML exported by a notation software called Notion.
When I try importing via Data > From Other Sources > From XML Data Import I get the attached error.

The attached XSD file was obtained from here http://www.musicxml.com/for-developers/ (do I need this XSD file? Or any other?)

How can I successfully import the XML file into Excel?
Thanks
XML-import-error.JPG
Yes-it-is---20150315.xml
musicxml.xsd
Avatar of Michael Fowler
Michael Fowler
Flag of Australia image

The problem is with the Doctype declaration. Quickest solution is to delete this from the xml. Then when you load it just ok the message and it will load correctly
Avatar of hindersaliva

ASKER

Hi Michael, is it just this that I need to remove?
<!DOCTYPE score-partwise PUBLIC
    "-//Recordare//DTD MusicXML 1.1 Partwise//EN"
    "http://www.musicxml.org/dtds/partwise.dtd">

Removing just that gave the same error.
Is there a closing tag to remove also?

Thanks
ASKER CERTIFIED SOLUTION
Avatar of Michael Fowler
Michael Fowler
Flag of Australia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Perfect!
Thank you Michael74.

I got one more related question ... would I use the XSD file to specify a schema? and if so how would I tell Excel to use it?
You can reference a local xsd with something like

<score-partwise version='1.1' xmlns="http://www.w3schools.com" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://www.w3schools.com file:///C://Users//USERNAME//Desktop//musicxml.xsd">
  <work>

Open in new window


problem is I could not get the XSD to work
Thanks Michael!