--- In flexcoders@yahoogroups.com, "Wally Kolcz" <wko...@...> wrote: > > > I seem to be missing something. I tried the suggested way: > > public function loginHandler(e:ResultEvent):void { > userData = e.result as ArrayCollection; > var object:Object = userData.getItemAt(0) ; > var firstName:String = object["FIRSTNAME"] ; > Alert.show(firstName); > } > > and I am getting this error: > > TypeError: Error #1009: Cannot access a property or method of a null object reference. > at index/loginHandler() > at index/___index_Operation3_result() > at flash.events::EventDispatcher/dispatchEventFunction() > at flash.events::EventDispatcher/dispatchEvent() > at mx.rpc::AbstractOperation/http://www.adobe.com/2006/flex/mx/internal:: dispatchRpcEvent() > at mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::re sultHandler() > at mx.rpc::Responder/result() > at mx.rpc::AsyncRequest/acknowledge() > at DirectHTTPMessageResponder/completeHandler() > at flash.events::EventDispatcher/dispatchEventFunction() > > How can I > change my backend script a bit in order to return an ArrayCollection of typed User objects? Any examples? >
You might find this example useful: http://flexdiary.blogspot.com/2009/01/lazy-loading-tree-example-file- posted.html