WS Client Protocol port problem?

R

robert

The 'add web reference' in Visual Studio 2002, along with WSDL.exe is broken. It seems that it is a problem with th

MS Web Services Client Protocol 1.0.3705.288, as both VS .Net and WSDL.exe use this to access the wsdl

If I have the wsdl available a

http://myserver:8080/services/MyService.wsd

The Project -> Add Web Reference shows the correct WSDL. But after using 'Add Reference' the WSDL file is incorrect. It seems that the request for the WSDL from within VS sets the HTTP 'Host' field incorrectly, in that, it does not append the port, even thogh the request is being sent to the non-default port. According to the HTTP spec this is incorrect

When requesting the WSDL via the browser (IE, or the Project -> Add Web Reference) the 'host' field is set correctly, as the protocol is

Is this a know bug? Has it been corrected in a later release

The work around is to manually edit the wsdl/generated class after retrieval to add the required port
 
D

Dino Chiesa [Microsoft]

Is this a know bug? Yes.

Has it been corrected in a later release?
Yes.

In .NET Framework v1.1, the problem no longer occurs.
The work around is to manually edit the wsdl/generated class after
retrieval to add the required port.Alternatively, you could manually specify the Url on the proxy class at
runtime.

eg

service = new MyProxy();
service.Url= "http://myhost:8080/whatever.asmx";
result= service.Method(...);
 

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,236
Members
46,822
Latest member
israfaceZa

Latest Threads

Top