[Mono-aspnet-list] When a web method returns DataTable the method generated in proxy class returns DataSet (Bug #360541)
Gonzalo Paniagua Javier
gonzalo.mono at gmail.com
Thu Apr 16 22:11:09 EDT 2009
On Fri, 2009-04-17 at 10:24 +1000, Jan van der watt wrote:
> Hi,
>
> I added a <%@ Assembly name="System.Data" %> to
> [TestWebServiceDataTable.aspx] but the effect is still the same.
>
> If you inspect the proxy file generate by running the web service
> (http://gdbe.webhop.org/ws/WebServiceDataTable.asmx?page=proxy),
> you'll see (towards the end) that DataSet is (still) used, instead of
> DataTable.
>
> (and while at the page, do you know why, when you go to the Test Form
> for the method, and Invoke it, you get "500 - OK Method HelloWorld not
> defined in service WebServiceDataTable" - this happens for all
> methods)
>
> Any other suggestions?
Ah! You get the exact same problem running under MS runtime. The
solution is to do something like:
DataSet ds;
bool success = ws.HelloWorld(out ds);
DataTable table = ds.Tables[0];
And that will give you your table.
-Gonzalo
More information about the Mono-aspnet-list
mailing list