cvc-elt.1: Não é possível encontrar a declaração do elemento 'MyElement'
Eu estou tentando validar um xml realmente simples usando xsd, mas por algum motivo eu recebo este erro. Eu realmente aprecio se alguém puder me explicar o porquê.
Arquivo XML
<?xml version="1.0" encoding="utf-8"?>
<MyElement>A</MyElement>
Arquivo XSD
<?xml version="1.0" encoding="UTF-8"?>
<schema xmlns="http://www.w3.org/2001/XMLSchema"
targetNamespace="http://www.example.org/Test"
xmlns:tns="http://www.example.org/Test"
elementFormDefault="qualified">
<simpleType name="MyType">
<restriction base="string"></restriction>
</simpleType>
<element name="MyElement" type="tns:MyType"></element>
</schema>