This message was discovered on microsoft.public.dotnet.framework.webservices.enhancements.
| shyam |
Hi, when I run wsdl.exe on a wsdl file, this is the cs file generated.
//////////////CS/////////////////// //--------------------------------------------------------- --------------------- // <autogenerated> // This code was generated by a tool. // Runtime Version: 1.1.4322.342 // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. // </autogenerated> //--------------------------------------------------------- ---------------------
// // This source code was auto-generated by wsdl, Version=1.1.4322.342. // using System.Diagnostics; using System.Xml.Serialization; using System; using System.Web.Services.Protocols; using System.ComponentModel; using System.Web.Services; using Microsoft.Web.Services;
/// <remarks/> [System.Diagnostics.DebuggerStepThroughAttribute()] [System.ComponentModel.DesignerCategoryAttribute("code")] [System.Web.Services.WebServiceBindingAttribute (Name="TcCCWsBinding", Namespace="http://my.com/cgi/TcCCWs.wsdl")] public class TcCCWs : Microsoft.Web.Services.WebServicesClientProtocol{ //System.Web.Services.Protocols.SoapHttpClientProto col {
/// <remarks/> public TcCCWs() { this.Url = "http://my.com:18000"; }
/// <remarks/> [System.Web.Services.Protocols.SoapRpcMethodAttribute ("", RequestNamespace="urn:TcCCWs", ResponseNamespace="urn:TcCCWs")] [return: System.Xml.Serialization.SoapElementAttribute ("files")] public System.Byte[][] getFiles() { object[] results = this.Invoke("getFiles", new object[0]); return ((System.Byte[][])(results[0])); }
/// <remarks/> [System.Web.Services.Protocols.SoapRpcMethodAttribute ("", RequestNamespace="urn:TcCCWs", ResponseNamespace="urn:TcCCWs")] [return: System.Xml.Serialization.SoapElementAttribute ("numFilesWritten")] public int putFiles(System.Byte[][] inputFiles) { object[] results = this.Invoke("putFiles", new object[] { inputFiles}); return ((int)(results[0])); } }
///////////////////////////////////////////////////////
I edited the base class to "Microsoft.Web.Services.WebServicesClientProtocol" and removed the async method for brevity.
When I try to use this and call the getFile method above, I get this error:
"System.Web.Services.Protocols.SoapHeaderException: The data in element 'wsrp:path' must be understood but cannot be handled\r\n at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadRe sponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)\r\n at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke (String methodName, Object[] parameters)\r\n at TcCCWs.getFiles()\r\n at TestTCCCWS.Client.Main(String[] args) in c:\\gsoap\\samples\\multidimeserv\\consoleapplication1 \\class1.cs:line 25"
Any help in resolving this is appreaciated;
|
|
| |
| |
| Fumiaki Yoshimatsu |
I guess your server doesn't understand the path element of WS-Routing in your header. SoapContext.Path.MustUnderstand = false; may suffice.
Fumiaki Yoshimatsu
"shyam" <Click here to reveal e-mail address> wrote in message news:003801c32aac$47d26c60$Click here to reveal e-mail address... [Original message clipped]
|
|
| |
| |
| shyam |
Hi, Does this need to be added to this cs file (generated from wsdl or in my .NET client that uses this cs?
Thanks for the tip.
[Original message clipped]
|
|
| |
|
| |
| Shyam |
Hi, Once I do this - I get this error:
"System.InvalidOperationException: Client found response content type of 'image/jpeg', but expected 'text/xml'.\r\nThe request failed with the error message
Any tip on why this could be? Thanks for any help.
[Original message clipped]
|
|
| |
| |
| Fumiaki Yoshimatsu |
It looks like your server does not send a valid SOAP/DIME message. It is not WSE, I guess. Conslut your service implementation.
Fumiaki Yoshimatsu
"Shyam" <aka_kumar@hotmail> wrote in message news:0b3d01c32b83$eebe60b0$Click here to reveal e-mail address... [Original message clipped]
|
|
| |
|
|
|
|
|
|
|