Hi Steve, The dataset which I am using in my Flex app is being edited, with some records added or deleted or filtered. As I am doing this in the Flex application, the backend service (web service) does not know which have been modified, thus, I need to send back the current data I have in the Flex application.
By the way, some updates on this. I tried to send the ArrayCollection as it is in .NET and I am getting the same as an ArrayList, which contains XML document tags. The only beef with this is that there is no actual tag for the field (column), so I have no idea which column to actually map back to the dataset. I am going to field portions of the data returned back tomorrow, as my codes are all in my office machine. Thanks and regards, Angelo ________________________________ From: valdhor <[email protected]> To: [email protected] Sent: Tuesday, 9 June, 2009 21:31:56 Subject: [flexcoders] Re: Flex and .NET I don't understand why you would send the entire data set back to your .NET backend via the web service. The backend has already generated the data to be sent and the backend is what generates the report via Crystal Reports. I would have thought the best way was to send the query back to the back end, get it to do the data lookup again and pass the data into Crystal Reports. HTH Steve --- In flexcod...@yahoogro ups.com, Angelo Anolin <angelo_anolin@ ...> wrote: > > > > Hi Sam, > > Thanks for your reply. > > As of now, I actually prefer to utilize what I know on .NET and what I am > learning on Flex. Adding another utility (Web Orb) in my learning process may > complicate things a bit. I might consult this later if I feel that the needs > for is getting tremendous. > > Anyway, I am actually able to generate the report from what I am currently > doing (no error encountered) , where the ArrayCollection I am parsing into a > delimited string, passing the string to the webservice call, and letting the > webservice de-serialize the string to populate a Crystal report document > which I subsequentlt display in another browser window which I call from the > Flex application. > > I mentioned that I did not feel it is the "BEST" way because I am literally > storing all datagrid (report) information in a string variable. Assuming for > example that the data displayed in the datagrid is quite huge, then creating > the delimited string would take some time and additional processing time > could also be consumbed by the back end web service to parse the string and > populate the report. > > As of now, this is what the application does. > 1. Flex App calls a webservice to retrieve data. > 2. WebService responds by sending back a dataset which is returned as a > string (via Dataset.GetXML method of .NET). > 3. Flex App gets the service response, converts the string into an XML. > 4. Flex App converts the XML data into an ArrayCollection which is bound to > the datagrid. > * Please note that I used array collection here for the search/filter > functionality of the datagrid. > 5. When generating print out of the data displayed in the datagrid, Flex > would then serialize the ArrayCollection into a delimited string and send it > to the web service. > 6. Web Service would then de-serialize (or parse) the string, populate a .NET > dataset which is the datasource for the Crystal report. > 7. Crystal report is bound and PDF report is generated. > 8. Flex displays via external javascript call the PDF report generated. > > Is there a better way for the ArrayCollection to be sent to the webservice, > the webservice in turn would just convert it to dataset and the dataset is > immediately bound to the Crystal report? > > Thanks. > > Regards, > > Angelo > > > ____________ _________ _________ __ > From: Sam Lai <samuel.lai@ ...> > To: flexcod...@yahoogro ups.com > Sent: Monday, 8 June, 2009 8:49:36 > Subject: Re: [flexcoders] Flex and .NET > > > > > > 2009/6/8 Angelo Anolin <angelo_anolin@ yahoo.com>: > > > I feel that this is probably not the "BEST" way of doing this. I tried > > initially to pass an XML delimmited string, but .NET seems to read XML > > differently( ?) from Flex. > > I'd say XML would be a good way of doing it. What kind of errors are > you getting, and how are you making the web service call? > > The other option is to use AMF, a native messaging format for > Flash/Flex. This I believe would save you the effort of serializing > and deserializing - it does it for you, among other things. > > http://www.themidni ghtcoders. com/products/ weborb-for- net/overview. html >

