Soap one request two responses
I'm trying to access a SOAP 1.1 WebService from .NET project. I reference the Service, create the Proxy. When i invoke the service it gives me an error: System.ArgumentException: An item with the same key has already been added
I invoke the Service using SOAPUi and service work fine. But when i see the httplog i notice that are two responses for the same reques开发者_如何学JAVAt.
First response give me an :"HTTP/1.1 401 Unauthorized[\r][\n]" Second response gives the the result OK. "HTTP/1.1 200 OK
I'm using the code in C#:
zenvia_estadoClient client = new zenvia_estadoClient("zenvia_estado");
client.ClientCredentials.UserName.Password = "MyPass";
client.ClientCredentials.UserName.UserName = "MyUser";
var resultado = client.ZmmIntEnviaEstado(new ZmmIntEnviaEstado() { PiBanfn= "something" });
client.Close();
精彩评论