Deserializing AMF Objects from WCF Service

Aug 18, 2010 at 10:33 PM

I'm wondering if some of you guys have a sample about how to deserialize an AMF object coming from a WCF Service implemented by using this project.

This is what I'm trying to do at Flash side:

private function getDataResult(obj:Object):void

 { var someData:MyData =new MyData();

getClassByAlias("DataServices.DataContracts.MyData");

someData = obj[0];

}

As you can imply from the previous source code I'm using the netConnection object in order to connect to the WCF Service.

I'm also using the getClassByAlias function in order to get the Action Script MyData class I previously registered by using this line of code in another part of the source code: registerClassAlias("DataServices.DataContracts.MyData",MyData) -"DataServices.DataContracts.MyData" is the fully qualified name for the MyData class at the WCF Service-

I'm receiving a type coercion error.

In the meantime I'm manually "deserializing" the object I'm getting from the WCF Service.  However, finding a way to do that automatically would be great.

Thanks in advance for your help!!!

Johann Granados