Hi Bo, It looks like you might have an extra space in your namespace declaration. Also, for convenience you may want to declare your targetNamespace with a prefix so you can refer to it in the schema.
try something like: <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.wwp.com/XMLSchema/moConfig.xsd" xmlns:tns="http://www.wwp.com/XMLSchema/moConfig.xsd" elementFormDefault="qualified"> ... <xs:attribute name="task" type="tns:stringListType" use="required"/> ... Please let the list know if you still have problems, -Jacob Danner On 9/5/07, Bo Wen <[EMAIL PROTECTED]> wrote: > Hi, > > When compiling schema through ant task, I got the following error. It seems > it is related to "targetNamespace". If I remove "targetNamespace", it works > fine. But I do need it to map schema to different java packages. > > Can anyone kindly help me out of this error? > > Thanks, > Bo > > [xmlbean] > C:\Workspace\ESM\conf\discovery\moConfig.xsd:15:13: error: > src-resolve.a: Could not find type 'stringListType@ > http://www.w3.org/2001/XMLSchema'. Do you mean to refer to > the type named > [EMAIL PROTECTED]://www.wwp.com/XMLSchema/moConfig.xsd > (in moConfig.xsd)? > > > File moConfig.xsd > ============= > <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" > targetNamespace=" > http://www.wwp.com/XMLSchema/moConfig.xsd" > elementFormDefault="qualified"> > <xs:simpleType name="stringListType"> > <xs:restriction base="xs:string"> > <xs:pattern value=".+(,.+)*"/> > </xs:restriction> > </xs:simpleType> > > <xs:element name="callTask"> > <xs:complexType> > <xs:attribute name="task" type="stringListType" use="required"/> > </xs:complexType> > </xs:element> > </xs:schema> > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

