The methods M1 and M2 use the same SOAPAction ''

T

TeeKayZee

I am developing a web service in VB.Net 2003 using a set of WSDL and XSD
files provided by the customer. I use the WSDL utility to create the proxy
class. I then create the web service. I test it by connecting with IE6 and it
displays all the methods. I can select each method in IE and everything
appears ok.

To build the client, I create a web reference to my web service. I then code
the calls to the web methods. When I run the client and try to call a method,
I get an error message: The methods M1 and M2 use the same SOAPAction ''.
(Note the empty string. I found an artical at
support.microsoft.com/default.aspx?scid=kb;en-us;323575 that points out that
a bug in VS.Net allows it to craete a web service that will not work because
the SOAP Action is the same in 2 or more methods. In my case, the SOAP Action
is "" for every method.

Am I doing something wrong when creating the proxy class? How should I
override the Must Overrider functions?

Many thanks!
 
T

TeeKayZee

Some more info: Earlier verisons of the WSDL & XSD files did not give me this
problem. They would create proxy functions like this:

<System.Web.Services.WebMethodAttribute(), _

System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://www.namespace/M1",
RequestNamespace:="http://www.namespace",
ResponseNamespace:="http://www.namespace",
Use:=System.Web.Services.Description.SoapBindingUse.Literal,
ParameterStyle:=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)> _
Public MustOverride Function M1(ByVal P1 As String) As M1

The new WSDL & XSD files create proxy functions like this:

<System.Web.Services.WebMethodAttribute(), _
System.Web.Services.Protocols.SoapDocumentMethodAttribute("",
Use:=System.Web.Services.Description.SoapBindingUse.Literal,
ParameterStyle:=System.Web.Services.Protocols.SoapParameterStyle.Bare)> _
Public MustOverride Function
M1(<System.Xml.Serialization.XmlElementAttribute([Namespace]:="http://www.namespace/schema")>
ByVal P1 As P1Type) As <System.Xml.Serialization.XmlElementAttribute("R1",
[Namespace]:="http://www.namespace/schema")> R1

Note that the 1st parameter of SoapDocumentMethodAttribute is empty for
every function, and ParameterStyle is Bare.

Any help would be appreciated.
 
T

TeeKayZee

I found the problem after a long search of the web, caused by a bug in VS.Net
compiler & a bug in the WSDL utility. Problem solved.
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,995
Messages
2,570,233
Members
46,820
Latest member
GilbertoA5

Latest Threads

Top