In article <Oy**************@TK2MSFTNGP12.phx.gbl>,
no****@nospam.com
says...
Hello,
I'm currently using Remoting (HTTP/Binary) to remote a simple object.
Everything is working fine except for one function that returns an arraylist
of datatables.
When I call this function, nothing is returned (ie length of array =0).
However, if I comment out my config file so that the DLL is run locally
instead of remoting it, everything works fine!!
So, my question is: Is there anything special that I need to do in order to
return an arraylist of datatables? Note: If I return a single datatable it
works fine, just the arraylist of dt's dont seem to work via remoting.....
Thanks in advance,
-ZD
Hi,
and what happens if you return an ArrayList, which contains some strings
only?
I this works, that as far as I remember there was some problems with
datatables/datasets with remoting. What you can do is to create a
dataset, which holds all these tables. The you export this dataset in
XML string and pass this string over remoting. You are not going to
loose any performance, as datasets are always serialized to XML, even
with binary formatter. Then on the client side you can recreate the
dataset from the string and access the tables. Nor very elegant
solution, but it should work.
If passing the arraylist with strings does not work, than most probably
you have some remoting configuration problem.
Also, you may try to capture the appdomain.Resove event and see if
during the serialization/deserialization there is some assembly missing.
Sunny