[Mono-devel-list] WSDL tool missing
Roland Troisch
rolandt at popmultimedia.com
Tue Jun 17 16:19:34 EDT 2003
So I hooked up mod-mono and the example pages are working ok but of
course, my web service consumer page isn't, hehe.
So to sum up:
My proxy class was generated with the VS.NET wsdl tool. It compiles ok
and works from a console app in mono.
I'm using the following test.aspx page:
<%@ Import Namespace="HelloWorld" %>
<%@ Language="C#" %>
<html>
<script language="C#" runat=server>
void Page_Load(Object sender, EventArgs e) {
//this is my proxy class in the HelloWorld
namespace
Tessitura comp = new Tessitura();
message.InnerHtml = comp.HelloWorld();
//message.InnerHtml = "test";
}
</script>
<body>
<div id="message" runat="server" />
</body>
</html>
where Tessitura is my class name for my proxy class which is residing in
the bin directory of the app. If I substitute that out for a different
class that is just a plain ole' biz object that writes 'hello world' and
doesn't use webservices, it works. Also, if I comment out the
HelloWorld method call, it doesn't fail (but of course does nothing).
But the web service proxy version trying to call HelloWorld() fails with
this error:
Error in '/mono' Application
------------------------------------------------------------------------
--------
Error
Description: Error processing request.
Error Message:
Stack Trace: System.NullReferenceException: A null value was found where
an object instance was requiredin <0x00044> 00
HelloWorld.Tessitura:HelloWorld ()in <0x0005e> 08
HelloWorld.Tessitura:HelloWorld ()in <0x0004a> 00
ASP.test_aspx:Page_Load (object,System.EventArgs)in <0x00081> 01
System.MulticastDelegate:invoke_void_object_EventArgs
(object,System.EventArgs)in <0x0008a> 00 System.Web.UI.Control:OnLoad
(System.EventArgs)in <0x00033> 00 System.Web.UI.Control:LoadRecursive
()in <0x000b8> 00 System.Web.UI.Page:ProcessRequest
(System.Web.HttpContext)in <0x001b9> 00 .ExecuteHandlerState:Execute
()in <0x00052> 00 .StateMachine:ExecuteState (IStateHandler,bool&)
Any suggestions?
Btw, here's the proxy class code too:
using System.Diagnostics;
using System.Xml.Serialization;
using System;
using System.Web.Services.Protocols;
using System.ComponentModel;
using System.Web.Services;
namespace HelloWorld
{
/// <remarks/>
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
[System.Web.Services.WebServiceBindingAttribute(Name="TessituraSoap",
Namespace="http://tessiturasoftware.com/")]
public class Tessitura :
System.Web.Services.Protocols.SoapHttpClientProtocol {
/// <remarks/>
public Tessitura() {
this.Url = "http://192.168.1.14/tessitura.asmx";
public Tessitura() {
this.Url = "http://192.168.1.14/tessitura.asmx";
}
/// <remarks/>
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tessi
turasof$
RequestNamespace="http://tessiturasoftware.com/",
ResponseNamespace="http://tessiturasoftware.com/",
Use=System.Web.Services.Description.SoapBindingUse.Literal,
ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)
]
public string HelloWorld() {
object[] results = this.Invoke("HelloWorld", new object[0]);
return ((string)(results[0]));
}
/// <remarks/>
public System.IAsyncResult BeginHelloWorld(System.AsyncCallback
callback, object asyncState) {
public System.IAsyncResult BeginHelloWorld(System.AsyncCallback
callback, object asyncState) {
return this.BeginInvoke("HelloWorld", new object[0], callback,
asyncState);
}
/// <remarks/>
public string EndHelloWorld(System.IAsyncResult asyncResult) {
object[] results = this.EndInvoke(asyncResult);
return ((string)(results[0]));
}
}
}
Thanks for any help you can provide everyone!
- rt
-----Original Message-----
From: Todd Berman [mailto:tberman at gentoo.org]
Sent: Tuesday, June 17, 2003 12:36 PM
To: Roland Troisch
Subject: RE: [Mono-devel-list] WSDL tool missing
POST is the only thing that is usable at all, its the only HTTP method
that allows data to be passed not through the url
so xsp wont work, but it is a known bug and gonzalo (System.Web guy)
will be getting to it hopefully very soon.
--Todd
On Tue, 2003-06-17 at 15:18, Roland Troisch wrote:
> I'm strictly using xsp right now. IIS and ASP.net are hosting the web
> service. Is post used by default for the proxy classes generated by
> wsdl?
>
> -----Original Message-----
> From: Todd Berman [mailto:tberman at gentoo.org]
> Sent: Tuesday, June 17, 2003 12:15 PM
> To: Roland Troisch
> Subject: RE: [Mono-devel-list] WSDL tool missing
>
> Are you using xsp as your server?
>
> I have found xsp cant POST with HttpWebRequest, where as mod_mono
POSTs
> without a problem.
>
> By the way, what are you using to host your webservice?
>
> --Todd
>
More information about the Mono-devel-list
mailing list