Hi,
I am getting the following errors on the schema (on the 'Fund_to' and 'Account_to' elements) in Visual Studio.NET when I try to validate the schema itself. I would greatly apreciate any help on this.
Error messages:
Z:\OrdertoFundSchema\OrdertoFundSchema\GridOrderXML.xsd(128): Type 'http://citco.com/NTASOrder.xsd:Fund' is not declared. An error occurred at Z:\OrdertoFundSchema\OrdertoFundSchema\GridOrderXML.xsd, (128, 15).
Z:\OrdertoFundSchema\OrdertoFundSchema\GridOrderXML.xsd(129): Type 'http://citco.com/NTASOrder.xsd:Account' is not declared. An error occurred at Z:\OrdertoFundSchema\OrdertoFundSchema\GridOrderXML.xsd, (129, 15).
XML where error is occurring:
<xs:element name="TransferInfo" minOccurs="0" maxOccurs="1"> <xs:complexType> <xs:sequence> <xs:element name="Fund_to" type="mstns:Fund" /> <xs:element name="Account_to" type="mstns:Account" /> </xs:sequence> </xs:complexType> </xs:element>
Full XML text:
<?xml version="1.0" ?>
<xs:schema id="Msg" targetNamespace="http://xxxxx.com/NNNNOrder.xsd" xmlns:mstns="http://xxxxx.com/NNNNOrder.xsd" xmlns="http://xxxxx.com/NNNNOrder.xsd" xmlns:xs="http://www.w3.org/2001/XMLSchema" attributeFormDefault="qualified" elementFormDefault="qualified"> <xs:simpleType name="udDate"> <xs:restriction base="xs:string"> <xs
attern value="\d\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|3[01])" /> </xs:restriction> </xs:simpleType> <xs:simpleType name="udTime"> <xs:restriction base="xs:string"> <xs
attern value="(0[0-9]|1[01])[:]([012345][0-9])" /> </xs:restriction> </xs:simpleType> <xs:element name="Msg"> <xs:complexType> <xs:choice maxOccurs="1"> <xs:element name="MsgHeader" minOccurs="1"> <xs:complexType> <xs:sequence> <xs:element name="MsgTypeId" minOccurs="1"> <xs:simpleType> <xs:restriction base="xs:string"> <xs:enumeration value="Ooottfff" /> </xs:restriction> </xs:simpleType> </xs:element> <xs:element name="MsgDate" minOccurs="1"> <xs:simpleType> <xs:restriction base="udDate" /> </xs:simpleType> </xs:element> <xs:element name="MsgTime" minOccurs="1"> <xs:simpleType> <xs:restriction base="udTime" /> </xs:simpleType> </xs:element> <xs:element name="SourceApp" minOccurs="1" type="xs:string"></xs:element> <xs:element name="MsgInitiator" type="xs:string" minOccurs="0" /> </xs:sequence> </xs:complexType> </xs:element> <xs:element name="MsgBody" maxOccurs="1"> <xs:complexType> <xs:sequence> <xs:element name="Order" minOccurs="1"> <xs:complexType> <xs:sequence> <xs:element name="TransactTypeId" minOccurs="1"> <xs:simpleType> <xs:restriction base="xs:string"> <xs:enumeration value="XX" /> <xs:enumeration value="YY" /> <xs:enumeration value="ZZ" /> <xs:enumeration value="AA" /> <xs:length value="2" /> </xs:restriction> </xs:simpleType> </xs:element> <xs:element name="CCOOSSS" minOccurs="1"> <xs:simpleType> <xs:restriction base="xs:string"> <xs:enumeration value="C" /> <xs:enumeration value="S" /> <xs:length value="1" /> </xs:restriction> </xs:simpleType> </xs:element> <xs:element name="SSHHHSS" minOccurs="1"> <xs:simpleType> <xs:restriction base="xs:decimal"> <xs:minInclusive value="0" /> <xs:fractionDigits value="7" /> <xs:totalDigits value="20" /> </xs:restriction> </xs:simpleType> </xs:element> <xs:element name="CCSSHHTTNDD" minOccurs="1"> <xs:simpleType> <xs:restriction base="xs:decimal"> <xs:minInclusive value="0" /> <xs:fractionDigits value="2" /> <xs:totalDigits value="20" /> </xs:restriction> </xs:simpleType> </xs:element> <xs:element name="TTTNNNTE" type="mstns:NNNNNote" minOccurs="0" /> <xs:element name="COMM" minOccurs="1"> <xs:simpleType> <xs:restriction base="xs:string"> <xs:enumeration value="S" /> <xs:enumeration value="I" /> <xs:enumeration value="N" /> <xs:enumeration value="E" /> <xs:length value="1" /> </xs:restriction> </xs:simpleType> </xs:element> <xs:element name="LoadPercent" type="mstns
ercentage" minOccurs="1" /> <xs:element name="TTDDTE" type="mstns:udDate" minOccurs="1" /> <xs:element name="NNNVVDTE" type="mstns:udDate"></xs:element> <xs:element name="Fund" minOccurs="1" maxOccurs="1"> <xs:complexType> <xs:sequence> <xs:element name="FFDDID" type="mstns:NNNNCode" minOccurs="1" /> <xs:element name="FDNME" type="xs:string" minOccurs="1" /> <xs:element name="EXTLID" type="xs:string" /> <xs:element name="EXTSYS" type="xs:string" /> </xs:sequence> </xs:complexType> </xs:element> <xs:element name="Account" minOccurs="1" maxOccurs="1"> <xs:complexType> <xs:sequence> <xs:element name="INVID" type="xs:string" minOccurs="1" maxOccurs="1" /> <xs:element name="FirstName" type="xs:string" minOccurs="0" /> <xs:element name="LastName" type="xs:string" minOccurs="0" /> <xs:element name="HLDID" type="mstns:NNNNCode" minOccurs="1" /> <xs:element name="ACTID" type="mstns:NNNNCode" minOccurs="1" /> <xs:element name="ACTNUM" type="mstns:NNNNCode" /> </xs:sequence> </xs:complexType> </xs:element> <xs:element name="ExternalReference" type="mstns:NNNNNote" minOccurs="1" maxOccurs="1"></xs:element> <xs:element name="TransferInfo" minOccurs="0" maxOccurs="1"> <xs:complexType> <xs:sequence> <xs:element name="Fund_to" type="mstns:Fund" /> <xs:element name="Account_to" type="mstns:Account" /> </xs:sequence> </xs:complexType> </xs:element> </xs:sequence> </xs:complexType> </xs:element> </xs:sequence> </xs:complexType> </xs:element> </xs:choice> </xs:complexType> </xs:element> <xs:simpleType name="NNNNCode"> <xs:restriction base="xs:string"> <xs:maxLength value="16" /> </xs:restriction> </xs:simpleType> <xs:simpleType name="Percentage"> <xs:restriction base="xs:decimal"> <xs:minInclusive value="0" /> <xs:maxExclusive value="100.00" /> <xs:fractionDigits value="2" /> </xs:restriction> </xs:simpleType> <xs:simpleType name="NNNNNote"> <xs:restriction base="xs:string"> <xs:maxLength value="45" /> </xs:restriction> </xs:simpleType> </xs:schema>
I am getting the following errors on the schema (on the 'Fund_to' and 'Account_to' elements) in Visual Studio.NET when I try to validate the schema itself. I would greatly apreciate any help on this.
Error messages:
Z:\OrdertoFundSchema\OrdertoFundSchema\GridOrderXML.xsd(128): Type 'http://citco.com/NTASOrder.xsd:Fund' is not declared. An error occurred at Z:\OrdertoFundSchema\OrdertoFundSchema\GridOrderXML.xsd, (128, 15).
Z:\OrdertoFundSchema\OrdertoFundSchema\GridOrderXML.xsd(129): Type 'http://citco.com/NTASOrder.xsd:Account' is not declared. An error occurred at Z:\OrdertoFundSchema\OrdertoFundSchema\GridOrderXML.xsd, (129, 15).
XML where error is occurring:
<xs:element name="TransferInfo" minOccurs="0" maxOccurs="1"> <xs:complexType> <xs:sequence> <xs:element name="Fund_to" type="mstns:Fund" /> <xs:element name="Account_to" type="mstns:Account" /> </xs:sequence> </xs:complexType> </xs:element>
Full XML text:
<?xml version="1.0" ?>
<xs:schema id="Msg" targetNamespace="http://xxxxx.com/NNNNOrder.xsd" xmlns:mstns="http://xxxxx.com/NNNNOrder.xsd" xmlns="http://xxxxx.com/NNNNOrder.xsd" xmlns:xs="http://www.w3.org/2001/XMLSchema" attributeFormDefault="qualified" elementFormDefault="qualified"> <xs:simpleType name="udDate"> <xs:restriction base="xs:string"> <xs