I am successfully using [Embed to embed an xml file into my 
application: 

[Bindable][Embed(source="map.xml")] public var map:Class;

Without the xml declaration everything works as intended, with the 
declaration present, I get the following error:
1086: Syntax error: expecting semicolon before namespaceUri.

Failing document:
<?xml version="1.0" encoding="utf-8"?>
<map namespaceUri="http://...";>
  <pt icon="Images">My Photo</pt>
  <pt icon="Sounds">My Music</pt>
</map>

Successful document:
<map namespaceUri="http://...";>
  <pt icon="Images">My Photo</pt>
  <pt icon="Sounds">My Music</pt>
</map>

Note these are exactly the same with one exception, the bad document 
has the xml declaration (<?xml version="1.0" encoding="utf-8"?>)

Any ideas on how to make this work with the declaration intact.

Reply via email to