Re: IXmlSerializable.GetSchema creates mutiple schema elements in my wsdl



"Jeremy" <nospam@xxxxxxxxxx> wrote in message news:ejg8CkVyHHA.5204@xxxxxxxxxxxxxxxxxxxxxxx
I've built a class that uses the IXmlSerializable interface to do custom serialization. I"ve then used the IXmlSerializable.GetSchema() method to output the schema of my class to the wsdl in my web service. The problem is that the schema of my class appears in a seperate schema element in the wsdl. It needs to be in the main schema element so that an application can consume the web service properly, because I've found that at least with .net apps, they only consume the first schema element. How can I get only one schema element in the wsdl?

Jeremy,

I'll try to look at this in more detail later, but for now have a comment: you are mistaken about .NET applications only consuming the first schema element. I have a production web service using four schemas. I did this by using wsdl:import elements outside of the <wsdl:types> element. It's apparently not WS-I compliant, but it works well. I intend (in my copious spare time) to see if I can do the equivalent by adding <schema> elements in the <wsdl:types> and using <xs:include> to load the "real" schemas.
--
John Saunders [MVP]

.



Relevant Pages

  • RE: dynamic xsd to webservice
    ... It's not as simple as just adding the XSD file itself to the WSDL, ... linking into the WSDL-generation system of ASP.Net, ... I'd like that schema to be part of the ... > in the web service, but the problem with that is that the schema could change ...
    (microsoft.public.dotnet.framework.aspnet.webservices)
  • Re: dynamic xsd to webservice
    ... with the web service and expose the schema in the wsdl and enable schema ... validation in the web service so as to keep me from having to validate the ... > I'm not 100% certain that you can add external schemas to your WSDL (I've ...
    (microsoft.public.dotnet.framework.aspnet.webservices)
  • Re: dynamic xsd to webservice
    ... I'm not 100% certain that you can add external schemas to your WSDL (I've ... but there is no reason why your web service could not do the ... > There is a schema located on a web address that I want to use ... > validate xml files formatted for that schema. ...
    (microsoft.public.dotnet.framework.aspnet.webservices)
  • Re: Unable to generate a temporary class (result=1
    ... If you've changed the schema and republished your web service, you likely need to have your clients re-create their local service proxy based on the new wsdl. ...
    (microsoft.public.biztalk.general)
  • IXmlSerializable.GetSchema creates mutiple schema elements in my wsdl
    ... output the schema of my class to the wsdl in my web service. ... It needs to be in the main schema element so that an application can ... public class AnyTextData2: AnyTextData, ...
    (microsoft.public.dotnet.framework.aspnet.webservices)

Loading