W3C home > Mailing lists > Public > xmlschema-dev@w3.org > February 2004

RE: Error during the validating of XML Schema

From: Ferrari GIanni <Ferrari.gi@apss.tn.it>
Date: Wed, 4 Feb 2004 10:28:04 +0100
Message-ID: <D11D57B75A3CD411BF7F00E018C3356F01865DCA@NTGEN05>
To: xmlschema-dev@w3.org
Thank you,

now i understand. So my parser give me the error because in the XML Schema
find an attribute empty, instead in the XML Schema the attribute is
required. Infact a string empty is "" instead a type integer empty have to
be "0" and not "". 

But, now I have a strange error. Look under this:


[Error] InvoiceXML.xml:8:83: cvc-complex-type.2.1: Element 'Service' must
have no character or element information item [children], because the type's
content type is empty.


And in my XML Schema, I declared the Element "Service" like:


<xsd:element name="DocumentSender" type="StructCompany" minOccurs="1"


<xsd:complexType name="StructCompany">


<xsd:element name="Service" type="AttrService" minOccurs="0" maxOccurs="1"/>







<xsd:complexType name="AttrService">

            <!-- Codice Servizio: centro di costo o di prelievo -->

            <xsd:attribute name="ServId" type="xsd:string" use="required"/>

            <!-- Nome Servizio -->

            <xsd:attribute name="ServName" type="xsd:string"

            <!-- Responsabile del Servizio -->

            <xsd:attribute name="ServResponsible" type="xsd:string"

            <!-- Telefono del servizio -->

            <xsd:attribute name="ServPhone" type="xsd:string"



So in my XXML Document I'll have:



<Service ServPhone="" ServResponsible="" ServName=""



What it the strange thing? Only an expert person like you can help me. Thank
you so much again.



Received on Wednesday, 4 February 2004 04:27:24 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 14:56:04 UTC