473,397 Members | 2,068 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,397 software developers and data experts.

Validating XML fragment with single namespace schema spread into multiple schema files using include.

Hi all,

I have a problem on validating a xml fragment using a single namespace
schema which spread across multiple schema files using include in the
master schema file. No matter how I change the xml fragment (to include
default namespace xmlns='urn:xxx:yy' and any other namespace it may
have), I still get the same error.

'urn:xxx:yy:Header' element is not declared. An error occurred at , (1,
2).

I have inspected the XmlSchema and its XmlSchemaObject, their SourceUri
are all the same (which is the master schema uri).

Is anybody have the same problem?

The code I was using is from the MSDN xml fragment validation, I have
altered it for testing, the only difference between that one and my one
is mine one have a schema using include to put other schema files into
a single namespace.

The "Header" element is in one of the included schema file, and it is a
child node of the root node, and of course the xml fragment only
contains this "Header" node and its child.

Please help.

Best regards

Wallace

Nov 18 '05 #1
1 2286
We would like you to post your schema and your code.

Thanks.

"Wallace" <Wa************@gmail.com> wrote in message
news:11**********************@g47g2000cwa.googlegr oups.com...
Hi all,

I have a problem on validating a xml fragment using a single namespace
schema which spread across multiple schema files using include in the
master schema file. No matter how I change the xml fragment (to include
default namespace xmlns='urn:xxx:yy' and any other namespace it may
have), I still get the same error.

'urn:xxx:yy:Header' element is not declared. An error occurred at , (1,
2).

I have inspected the XmlSchema and its XmlSchemaObject, their SourceUri
are all the same (which is the master schema uri).

Is anybody have the same problem?

The code I was using is from the MSDN xml fragment validation, I have
altered it for testing, the only difference between that one and my one
is mine one have a schema using include to put other schema files into
a single namespace.

The "Header" element is in one of the included schema file, and it is a
child node of the root node, and of course the xml fragment only
contains this "Header" node and its child.

Please help.

Best regards

Wallace

Nov 23 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: maddalimurali | last post by:
Hello all, My xml and schema file header are as follows. 1) cisGlobals.xsd. <?xml version="1.0" encoding="UTF-8"?> <xsd:schema targetNamespace="http://www.talgov.com/cisGlobals"...
1
by: Mark Olbert | last post by:
I am trying to validate an XML file that does not contain any xmlns: namespace attribute against a predefined XSD schema. I should think this would be easy to do, since there must be far more...
6
by: Iain | last post by:
I've got a system which takes an XML file, translates it into an update gram and then loads it into my database with SQLXML3 (all in dot net). But it's fragile. And the SQLXML 3 error reporting...
0
by: Adam Smith | last post by:
Hello. I've got a total of 5 schemas. They are: 1 - 1.xsd - a description of a city 2 - 2.xsd - a description of a town 3 - CityHall.xsd - a description of a cityhall-meant to be part of a...
1
by: Brendon | last post by:
I have 2 Xsd's The one contains basic type definitions <?xml version="1.0" encoding="utf-8"?> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified"...
4
by: bibsoconner | last post by:
Hi, I hope someone can please help me. I'm having a lot of trouble with schema files in .NET. I have produced a very simple example that uses "include" to include other schema files. It all...
0
by: wolf_y | last post by:
I'm a newbie to XML and primarily program in SAS, so even though I've consulted documentation, I can't translate into language I understand. I hope I can explain the problem clearly. The project...
1
by: Chris Lieb | last post by:
I have an XML Schema file that I know is correct becuase I currently use it in a VB6 program to validate XML documents. Also, if I load an XML file into VS2005 that is not valid against this...
3
by: vhrao | last post by:
I am trying to validate a xml file with two schema files cust.xsd and cust1.xsd. The schema file cust.xsd allows addition of elements from another schema cust1.xsd by using xs:any wildcard. ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.