I created a Schema (see below) in VS.NET. I then tried to create an XML
document so that I could enter data for it. It gives me the error "An
Error occurred while loading the schema with targetNameSpace
"http://tempuri.org/Folderlist.xsd" referenced in the document. Index(zero
based) must be greater than or equal to zero and less than the size of the
argument list."
Any ideas what could be causing this?
Andy D
XSD:
<?xml version="1.0" encoding="utf-8" ?>
<xs:schema id="Folderlist"
targetNamespace="http://tempuri.org/Folderlist.xsd"
elementFormDefault="qualified"
xmlns="http://tempuri.org/Folderlist.xsd"
xmlns:mstns="http://tempuri.org/Folderlist.xsd"
xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:complexType name="Folders">
<xs:sequence>
<xs:element name="BackupSets" type="BackupSet"
minOccurs="0" maxOccurs="unbounded" />
</xs:sequence>
</xs:complexType>
<xs:complexType name="BackupSet">
<xs:sequence>
<xs:element name="FoldersToBackup" type="FolderList"
maxOccurs="1" minOccurs="1" />
<xs:element name="DestinationFolder" type="xs:string"
maxOccurs="1" minOccurs="1" />
<xs:element name="BackupTime" type="xs:time"
minOccurs="1" maxOccurs="unbounded" />
</xs:sequence>
</xs:complexType>
<xs:complexType name="FolderList">
<xs:sequence>
<xs:element name="Folder" type="xs:string" minOccurs="1"
maxOccurs="unbounded" />
</xs:sequence>
</xs:complexType>
</xs:schema>
XML file:
<?xml version="1.0" encoding="utf-8" ?>
<root xmlns="http://tempuri.org/Folderlist.xsd"></root>