472,995 Members | 1,790 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

Does XSD <Import> work?


Environment: Visual Studio .NET 2003 (vb)

I am developing an XSD Schema and want to include some building blocks from
another source, so they have a different namespace.
- If I use an <Include> the Schema doesn't show any of the Elements from the
include Schema. But that's to be expected because they are in a different
- If I use <Import> the Schema doesn't show any of the Elements from the
import Schema
- If I use both <Include> and <Import> I get the same result as just using
- If both Schemas are in the same namespace it works fine with <Include>.
But that's not what I want to do.

The documentation for Import documentation:
"....import element allows references to schema components from schema
documents with different target namespaces"

So, I conclude that <Import> doesn't work. Or is there another answer?

Without Import I can't generate Datasets.
An example below.

The same problem appears to occur when trying to add Web References (or use
the WSDL.EXE tool). It does not appear to accept <Import> directives.

<?xml version="1.0" encoding="utf-8" ?>
<xsd:schema id="MainSchema"
<xsd:import namespace="urn:schema-b" schemaLocation="schema_b.xsd" />
<xsd:element name="Element1">
<xsd:element ref="Element2" />
<xsd:element ref="Element3" />

<?xml version="1.0" encoding="UTF-8" ?>
attributeFormDefault="unqualified" >
<xsd:element name="Element2">
<xsd:element name="Element21" type="Timestamp">
<xsd:element name="Element22" type="xsd:string">
<xsd:element name="Element3">
<xsd:element name="Element31" type="xsd:string">
Nov 12 '05 #1
1 4263
WSDL.exe doesnt allow for using the "include", it would give you a binding error. One way to get over this is to, have the schema inside the same xsd document.

Hope that helps.

Nov 12 '05 #2

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

Similar topics

by: John Tiger | last post by:
Can anybody have idea about the difference between #include <iostream.h> and #include <iostream>. Is later one valid statement on any compiler. I tried compiling on MSVC second statement give...
by: Paul Scotchford | last post by:
Env : SLQSERVER2000 - DTS I want to import a text file with 3 fields in it ... F1: Ident char(3) F2: Note (Text) char(32,000) yeah big eh! F3: Date Field F2: has...
by: Markus Seibold | last post by:
Hello NG, sorry for pasting that much code but I just can't figure out how get the <key><keyref> to work in XML Schema. I am using XMLSpy 4.3 for editing my XML. I want to represent a...
by: Bernd Oninger | last post by:
As far as I know one could use other xsd schemas with the import and the xlink feature. What are the differences (beside the syntax)? Bernd
by: Sammy | last post by:
Hi, my mind is going crazy. I have tried everything I can think of to no avail. I have tried Disable Output Escaping. I tried to think of a way of enclosing the attribute data in a CDATA...
by: Wolfgang Kaml | last post by:
I am not sure if this is more of an expert question, but I am sure that they are out there. I'd like to setup a general application or bin directory on my Win2003.Net Server that will hold some...
by: seeCoolGuy | last post by:
I've been using Access to import some data straight into a sql server database by simply importing the xml file. However lately some of the newer xml files will contain vaild data such as ...
by: mark | last post by:
Hi All, Apologies for the newbie question but I've searched and tried all sorts for a few days and I'm pulling my hair out ; Please feel free to teach me to suck eggs because it's all new to me...
by: kvnsmnsn | last post by:
Over the course of my career I've transitioned from an Ada programmer (am I dating myself?) to a C programmer to a Java programmer and now back to a C programmer with the job I've currently...
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 4 Oct 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
by: Aliciasmith | last post by:
In an age dominated by smartphones, having a mobile app for your business is no longer an option; it's a necessity. Whether you're a startup or an established enterprise, finding the right mobile app...
by: Teri B | last post by:
Hi, I have created a sub-form Roles. In my course form the user selects the roles assigned to the course. 0ne-to-many. One course many roles. Then I created a report based on the Course form and...
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 1 Nov 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM) Please note that the UK and Europe revert to winter time on...
by: nia12 | last post by:
Hi there, I am very new to Access so apologies if any of this is obvious/not clear. I am creating a data collection tool for health care employees to complete. It consists of a number of...
by: NeoPa | last post by:
Introduction For this article I'll be focusing on the Report (clsReport) class. This simply handles making the calling Form invisible until all of the Reports opened by it have been closed, when it...
by: isladogs | last post by:
The next online meeting of the Access Europe User Group will be on Wednesday 6 Dec 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, Mike...
by: GKJR | last post by:
Does anyone have a recommendation to build a standalone application to replace an Access database? I have my bookkeeping software I developed in Access that I would like to make available to other...

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.