[Mono-list] Re: Simple web method always returns error 500
"Cannot cast from source type to destination type" SOLVED
Lluis Sanchez
lluis@ximian.com
Mon, 09 Feb 2004 17:03:04 +0100
Hi,
Inheritance from System.Web.Services.WebService should be not required.
We must be doing an unneeded cast somewhere. I'll fix that.
Lluis.
On dg, 2004-02-08 at 05:20, Peter Wolf wrote:
> Hey,
>
> I just figured that I forgot to add the inheratence from
> System.Web.Services.WebService to my Test class.
> Now it works!
>
> strange but Microsoft's .NET works without this... hmm.
>
> Anyway, have a great day
>
> Peter
>
>
>
> ----- Original Message -----
> From: "Peter Wolf" <p_wol@hotmail.com>
> To: <mono-list@lists.ximian.com>
> Sent: Saturday, February 07, 2004 3:20 PM
> Subject: Simple web method always returns error 500 "Cannot cast from source
> type to destination type"
>
>
> > Hi .NET people,
> >
> > I have created a simple web method just to test the webservice the mono
> 0.3
> > It's compiled OK but the method returns the following:
> >
> > The remote server returned an error: (500) Internal Server Error. Cannot
> > cast from source type to destination type
> >
> > here is my code (test.asmx)
> >
> > <%@ WebService Language="C#" class="Test"%>
> > using System;
> > using System.Web.Services;
> >
> > public class Test
> > {
> > [WebMethod]
> > public int test()
> > {
> > return 0;
> > }
> > }
> >
> > Please help! Thanks!!!
> >
> _______________________________________________
> Mono-list maillist - Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list