Thanks Roberto, I tried your sample and it worked. Now that I see the error message again I know what the issue is.... you don't have a reference to mx.collections.ArrayCollection so this class definition isn't linked into the SWF during compilation...
Typically if a typed object's class isn't found the player just creates an anonymous Object, however mx.collections.ArrayCollection implements, which means it controls its own serialization and can't be skipped by the player... so we end up (unfortunately) with this generic error.
In your MXML add a line in Script like this:
import mx.collections.ArrayCollection;
private var dep:ArrayCollection;
That should be enough to force a dependency on this class so that it is linked into the SWF.
We fixed this after Beta 3 to always have a dependency on this class when using RPC services.

From: [mailto:[EMAIL PROTECTED] On Behalf Of Peter Farland
Sent: Tuesday, June 20, 2006 9:44 AM
Subject: RE: [flexcoders] Converting Java objects to ActionScript

Roberto, in flex-enterprise-services.xml, can you go to the logging section, set the level to Debug and then make sure the only logging pattern is Endpoint.*. Restart the server and then rerun your application and look on the console (if you started the server using the command line) or in the app server's std err/out logs and see if you can provide more information?
Otherwise, you can send me a zip offlist (remember to rename the .zip extension to something else, like .z so that the email filter doesn't discard it) of the server code so I can take a closer look.

From: [mailto:[EMAIL PROTECTED] On Behalf Of hans73it
Sent: Tuesday, June 20, 2006 4:19 AM
Subject: [flexcoders] Converting Java objects to ActionScript

I'm trying to call a remote object that returns a List of String.

After I've invoked the method Flex throws this Error:

ArgumentError: Error #2004: One of the parameters is invalid.

myFault: (mx.messaging.messages::ErrorMessage)#0
body = (Object)#1
clientId = (null)
correlationId = "6D027356-DA87-5CBB-9C7D-F07EFBCDE4F0"
destination = ""
extendedData = (null)
faultCode = "Server.Acknowledge.Failed"
faultDetail = "Was expecting
mx.messaging.messages.AcknowledgeMessage, but received null"
faultString = "Didn't receive an acknowledge message"
headers = (Object)#2
messageId = "D11F9A89-1A82-88CD-AF17-F07EFF841B75"
rootCause = (null)
timestamp = 0
timeToLive = 0

I also have this error with a Set class as result...Flex
documentation said that a Java Collection is converted in an
ActionScript ArrayCollection...I'm missing something?

-I'm using the JDK5.0, Flex beta3, tomcat 5.5.17
-If I use a Map object as result, it works...



Flexcoders Mailing List
Search Archives:

Web site design development Computer software development Software design and development
Macromedia flex Software development best practice



Reply via email to