EDN Admin
Well-known member
<span style="font-size:xx-small <span style="font-family:Arial; color:#0000ff; font-size:x-small <span style="font-family:Arial; color:#0000ff; font-size:x-small <span style="font-family:Arial; color:#0000ff; font-size:x-small Im getting divergent
results when looking at the google kml files - xml spy 2011 is stating that <br/>
"The abstract attribute of element <KmlSimpleExtensionGroup> must be set to false." whilst VS2010<br/>
is quite happy about it, even to the extent of giving a list of 27 xsi-types from which to choose.<br/>
Clearly they both cant be correct - are there any MS xsd schema gurus out there who might be able to provide a definitive answer?
<span style="font-size:xx-small <span style="font-family:Arial; color:#0000ff; font-size:x-small <span style="font-family:Arial; color:#0000ff; font-size:x-small <span style="font-family:Arial; color:#0000ff; font-size:x-small
<br/>
Quick steps to reproduce <br/>
xml file used:<br/>
<br/>
<pre><?xml version="1.0" encoding="UTF-8"?>
<kml xmlns:gx="http://www.google.com/kml/ext/2.2" xmlns="http://www.opengis.net/kml/2.2" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:xal="urnasis:names:tc:ciq:xsdschema:xAL:2.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.google.com/kml/ext/2.2 file:///D:/SamplesFinal/KML/Orig/kml22gx.xsd
<NetworkLinkControl>
<minRefreshPeriod>0.0</minRefreshPeriod>
</NetworkLinkControl>
<Document/>
<KmlSimpleExtensionGroup xsi:type="angle180Type 180</KmlSimpleExtensionGroup>
<KmlObjectExtensionGroup xsi:type="gx:FlyToType
<gx:duration>99</gx:duration>
<gx:flyToMode>smooth</gx:flyToMode>
</KmlObjectExtensionGroup>
</kml>[/code]
<span style="font-family:Courier New The original xsds can be downloaded from
http://code.google.com/apis/kml/schema/kml22gx.xsd http://code.google.com/apis/kml/schema/kml22gx.xsd <br/>
The only thing Ive changed is to make the 4 xsds local (so no full paths in the schemaLocation)
<br/>
that is I saved them all locally in the same directory. <br/>
<span style="font-family:Courier New Of course removing abstract="true" from the line
<br/>
<element name="KmlSimpleExtensionGroup" type="anySimpleType" abstract="true"/> (and also from
<br/>
<element name="KmlObjectExtensionGroup" abstract="true" substitutionGroup="kml:AbstractObjectGroup"/>)<br/>
solves the problem of the xml now being valid (and also results in a schema whereby these last 2 elements in
<br/>
kmlType can now be derived from which is surely what the author/s intended!), however it doesnt explain why dotnet was previously saying it was valid.
<br/>
<br/>
Thoughts anyone?
<span style="font-family:Courier New <br/>
(repost from ASMX Web Services and XML Serialization - why cant you change which forum somethings posted to?!)
View the full article
results when looking at the google kml files - xml spy 2011 is stating that <br/>
"The abstract attribute of element <KmlSimpleExtensionGroup> must be set to false." whilst VS2010<br/>
is quite happy about it, even to the extent of giving a list of 27 xsi-types from which to choose.<br/>
Clearly they both cant be correct - are there any MS xsd schema gurus out there who might be able to provide a definitive answer?
<span style="font-size:xx-small <span style="font-family:Arial; color:#0000ff; font-size:x-small <span style="font-family:Arial; color:#0000ff; font-size:x-small <span style="font-family:Arial; color:#0000ff; font-size:x-small
<br/>
Quick steps to reproduce <br/>
xml file used:<br/>
<br/>
<pre><?xml version="1.0" encoding="UTF-8"?>
<kml xmlns:gx="http://www.google.com/kml/ext/2.2" xmlns="http://www.opengis.net/kml/2.2" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:xal="urnasis:names:tc:ciq:xsdschema:xAL:2.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.google.com/kml/ext/2.2 file:///D:/SamplesFinal/KML/Orig/kml22gx.xsd
<NetworkLinkControl>
<minRefreshPeriod>0.0</minRefreshPeriod>
</NetworkLinkControl>
<Document/>
<KmlSimpleExtensionGroup xsi:type="angle180Type 180</KmlSimpleExtensionGroup>
<KmlObjectExtensionGroup xsi:type="gx:FlyToType
<gx:duration>99</gx:duration>
<gx:flyToMode>smooth</gx:flyToMode>
</KmlObjectExtensionGroup>
</kml>[/code]
<span style="font-family:Courier New The original xsds can be downloaded from
http://code.google.com/apis/kml/schema/kml22gx.xsd http://code.google.com/apis/kml/schema/kml22gx.xsd <br/>
The only thing Ive changed is to make the 4 xsds local (so no full paths in the schemaLocation)
<br/>
that is I saved them all locally in the same directory. <br/>
<span style="font-family:Courier New Of course removing abstract="true" from the line
<br/>
<element name="KmlSimpleExtensionGroup" type="anySimpleType" abstract="true"/> (and also from
<br/>
<element name="KmlObjectExtensionGroup" abstract="true" substitutionGroup="kml:AbstractObjectGroup"/>)<br/>
solves the problem of the xml now being valid (and also results in a schema whereby these last 2 elements in
<br/>
kmlType can now be derived from which is surely what the author/s intended!), however it doesnt explain why dotnet was previously saying it was valid.
<br/>
<br/>
Thoughts anyone?
<span style="font-family:Courier New <br/>
(repost from ASMX Web Services and XML Serialization - why cant you change which forum somethings posted to?!)
View the full article