tool WSDL error

Discussion in 'ASP .Net Web Services' started by Matt R, Mar 30, 2005.

  1. Matt R

    Matt R Guest

    I have a WSDL on the network that defines a service that I wish to consume.

    Having added a reference to the wsdl to my project , and tried to build the
    project I get the following error.

    "c:\inetpub\wwwroot\TestInterfaces\Web
    References\UserServices\Reference.map(1): Custom tool error: Unable to
    import WebService/Schema. Unable to import binding 'userFacadeSoapBinding'
    from namespace 'facade.soap.gateway.b.org.uk'. Unable to import operation
    'getUser'. Schema with targetNamespace='http://dto.soap.gateway.b.org.uk'
    has invalid syntax. The 'ref' attribute cannot be present."

    1) Renaming all instances of dto in my project with another string still
    causes the above error. (I checked that there were no dto's in the included
    files as well

    2) I have duplicated the definitions schema and replaced all elements with
    complex types so I can remove the refs, and still get the same error.

    3) I have removed all references to getUser from the wsdl, but still the
    same error persists.

    So, what else can I try?

    I initially thought it was a namespace problem, but after doing all the
    above, (and rebuilding each time) I am now not so sure.

    Any help at all greatfully received
     
    Matt R, Mar 30, 2005
    #1
    1. Advertising

  2. Matt R

    Lionel LASKE Guest

    Are you sure your WSDL is correct ? Your error message is strange: "ref" is
    for "reference" on an object and it's forbidden in WSDL.
    Could you post the full WSDL ?

    Lionel.

    "Matt R" <matthewr at Becta.org.uk> a écrit dans le message de news:
    ...
    >I have a WSDL on the network that defines a service that I wish to consume.
    >
    > Having added a reference to the wsdl to my project , and tried to build
    > the
    > project I get the following error.
    >
    > "c:\inetpub\wwwroot\TestInterfaces\Web
    > References\UserServices\Reference.map(1): Custom tool error: Unable to
    > import WebService/Schema. Unable to import binding 'userFacadeSoapBinding'
    > from namespace 'facade.soap.gateway.b.org.uk'. Unable to import operation
    > 'getUser'. Schema with targetNamespace='http://dto.soap.gateway.b.org.uk'
    > has invalid syntax. The 'ref' attribute cannot be present."
    >
    > 1) Renaming all instances of dto in my project with another string still
    > causes the above error. (I checked that there were no dto's in the
    > included
    > files as well
    >
    > 2) I have duplicated the definitions schema and replaced all elements with
    > complex types so I can remove the refs, and still get the same error.
    >
    > 3) I have removed all references to getUser from the wsdl, but still the
    > same error persists.
    >
    > So, what else can I try?
    >
    > I initially thought it was a namespace problem, but after doing all the
    > above, (and rebuilding each time) I am now not so sure.
    >
    > Any help at all greatfully received
    >
    >
     
    Lionel LASKE, Mar 30, 2005
    #2
    1. Advertising

  3. Matt R

    Matt R Guest

    Theplot thickens. I just removed the WebReferences and recreated them, and
    now get this message

    "c:\inetpub\wwwroot\TestInterfaces\Web
    References\UserServices\Reference.map(1): Custom tool error: Unable to
    import WebService/Schema. Unable to import binding 'userFacadeSoapBinding'
    from namespace 'facade.soap.gateway.b.org.uk'. Unable to import operation
    'createUser'. The datatype 'User' is missing."

    User is defined in the WSDL, not the schema with all the other definitions.
    The more I look at this the more I think its a namespace issue. The WSDL is
    produced from a java tool, and I am assured that it is ok.

    The wsdl is long, but the section at the top is posted below..

    <?xml version="1.0" encoding="UTF-8"?>

    <wsdl:definitions targetNamespace="facade.soap.gateway.b.org.uk"

    xmlns:apachesoap="http://xml.apache.org/xml-soap"

    xmlns:impl="facade.soap.gateway.b.org.uk"

    xmlns:intf="facade.soap.gateway.b.org.uk"

    xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"

    xmlns:tns1="http://dto.soap.gateway.b.org.uk"

    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"

    xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"

    xmlns:b="http://bdefinitions.soap.gateway.b.org.uk"

    xmlns:xsd="http://www.w3.org/2001/XMLSchema">

    <wsdl:import namespace="http://bdefinitions.soap.gateway.b.org.uk"
    location="file:./bdefinitions.xsd"/>

    <wsdl:types>

    <schema targetNamespace="http://common.gateway.b.org.uk"
    xmlns="http://www.w3.org/2001/XMLSchema">

    <import namespace="http://dto.soap.gateway.b.org.uk"/>

    <import namespace="facade.soap.gateway.b.org.uk"/>

    <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>

    </schema>


    <schema targetNamespace="facade.soap.gateway.b.org.uk"
    xmlns="http://www.w3.org/2001/XMLSchema">

    <import namespace="http://common.gateway.b.org.uk"/>

    <import namespace="http://dto.soap.gateway.b.org.uk"/>

    <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>

    <complexType name="ArrayOf_xsd_String">

    <complexContent>

    <restriction base="soapenc:Array">

    <attribute type="soapenc:arrayType" wsdl:arrayType="string[]"/>

    </restriction>

    </complexContent>

    </complexType>

    </schema>


    <schema targetNamespace="http://matx.soap.gateway.b.org.uk"
    xmlns="http://www.w3.org/2001/XMLSchema">

    <import namespace="http://common.gateway.b.org.uk"/>

    <import namespace="facade.soap.gateway.b.org.uk"/>

    <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>

    <complexType name="User">

    <sequence>

    <element name="contractIds" nillable="true" type="impl:ArrayOf_xsd_String"/>

    <element name="id" nillable="true" type="xsd:string"/>

    <element name="userDetails" nillable="true" type="b:userdetails"/>

    <element name="organisationDetails" nillable="true"
    type="b:eek:rganisationdetails"/>

    <element name="accessDetails" nillable="true" type="b:accessdetails"/>

    </sequence>

    </complexType>

    </schema>


    </wsdl:types>

    the bdefinitions and the wsdl are on a network drive if that has any
    bearing.

    Matt




    > Are you sure your WSDL is correct ? Your error message is strange: "ref"

    is
    > for "reference" on an object and it's forbidden in WSDL.
    > Could you post the full WSDL ?
    >
    > Lionel.
     
    Matt R, Mar 31, 2005
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Dark
    Replies:
    1
    Views:
    4,640
    milfar
    Nov 14, 2008
  2. Chris Bedford
    Replies:
    0
    Views:
    590
    Chris Bedford
    Aug 21, 2003
  3. Stephen Edgecombe

    WSDL.EXE: WSDL Import Directive

    Stephen Edgecombe, Aug 13, 2003, in forum: ASP .Net Web Services
    Replies:
    0
    Views:
    242
    Stephen Edgecombe
    Aug 13, 2003
  4. RH
    Replies:
    1
    Views:
    268
    Dino Chiesa [Microsoft]
    May 27, 2004
  5. mrnu

    wsdl.exe fails with WebMethods generated wsdl file

    mrnu, Jun 7, 2004, in forum: ASP .Net Web Services
    Replies:
    0
    Views:
    214
Loading...

Share This Page