Does anyone know if flex application will be able to handle
multiple output parameters from a .net webservice method? I can
easily get the response I want, when a web service is returning
only 1 output parameter. all output parameters are of type string
having valid xml.
Web Service Code:
public string GetUserList(string strUserName, out String
String ErrorXml = null;
//call to next layer which returns User list in xml format
in 'UserListXml' value or ErrorXml if any
//e.g. UserListXml =
and ErrorXml = null
//Or UserListXml = null and ErrorXml =
if I specify resultFormat="object" , I will get xml value
corresponding to 'ErrorXml' parameter.
and when I specify resultFormat="e4x" , I will get xml
structure for result but value corresponding to 'UserListXml'
parameter is returend as plain string
e.g: <User>1</User> is returned as
the short answer for your question is yes, flex can handle
multiple output parameters.
Now the fun part, the best way to work with flex and .net is
to use what is called a data transfer object wich means you should
be using arraylists to pass an array of classes from .net and put
it together on flex as an array collection too. I don't have here
code for you by try search google for data transfer objects. I work
with them a lot and it works with .net 1.1 or above framework.
As for your application, you are sending your result from
.net to flex as a String so that's why flex treats it as a string
when you put it as E4X because you are not retuning a valid XML
format. As an object you get better results.
Thanks a lot.
But as this web service is third party component its not
possible for me to change its sytanx. I need to access this as it
is from flex 2.
I am not getting How to use data transfer object in this
Can you please explain with some example?
It would be a gr8 help.