Author Topic: xml validation  (Read 3623 times)

RG_Basser

  • Community Member
  • Posts: 20
  • Hero Points: 0
xml validation
« on: May 05, 2009, 03:23:04 PM »
Hi @all,

since I changed from 12.0.3 to 13.0.2 I have problems validating my XML files.
I use some xsd files generated with "Liquid XML Studio" to validate my XML files.
In my XML files I refer to a main xsd file (let's say user1.xsd) which includes some
other xsd files (let's say user2.xsd, user3.xsd, ...).

In my XML file I refer to the main xsd file "user1.xsd" by the following way
(which I was suggested to do by Dennis some times ago):

Code: [Select]
<graphic xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="file:../../../../../../user1.xsd">
...
</graphic>

And "user1.xsd" has the following lines inside:

Code: [Select]
<xs:schema elementFormDefault="qualified" xmlns:xs="http://www.w3.org/2001/XMLSchema">
  <xs:include schemaLocation="user2.xsd" />
  <xs:include schemaLocation="user3.xsd" />
  ...

Everytime I validate my XML file the following error occurs:
  19 27: Error Cannot open user2.xsd

"user2.xsd" and "user3.xsd" are located at the same place as "user1.xsd" does.
Some of you may have noticed that I refer to "user1.xsd" relative to my XML file.
I found out that inserting the same relative path to the line where "user2.xsd" is included
helps to find "user2.xsd":

Code: [Select]
<xs:include schemaLocation="../../../../../../user2.xsd"
But this can't be the solution ??? "user2.xsd" should be found relative to "user1.xsd" and not relative
to my XML file!!! Like I said before that all worked fine in vs 12.0.3 :'(

Thanks for any help!!