I am trying to create classes from a xsd file using xsd.exe, but get this:
Warning: cannot generate classes because no top-level elements with complex type were found.
<?xml version="1.0" encoding="UTF-8"?>
<!-- edited with XMLSpy v2008 sp1 (http://www.altova.com) by (EMBRACE) -->
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:ns1="http://comp.com/service/model/extension" targetNamespace="http://comp.com/service/model/extension">
<xs:complexType name="attachment">
<xs:sequence>
<xs:element name="fileIdentifier" type="xs:string" minOccurs="0"></xs:element>
</xs:sequence>
</xs:complexType>
<xs:complexType name="metadataSystem">
<xs:sequence>
<xs:element name="activityId" type="xs:string" minOccurs="0"></xs:element>
<xs:element name="from" type="xs:long" minOccurs="0"></xs:element>
<xs:element name="href" type="xs:string" minOccurs="0"></xs:element>
<xs:element name="performers" type="xs:long" minOccurs="0"></xs:element>
</xs:sequence>
</xs:complexType>
</xs:schema>
Where I have this top-level elements? If I add:
<xs:element name="attachment" type="attachment" />
I get this:
Missing type "attachment"
This question don't help, adding element tag throw new error.