Hi there,
I know, this topic is kinda old but I still have the same problem and I'm totally surprised that I'm, obviously, the only one.
All comes back to this article
http://www.adobe.com/devnet/flex/articles/datadriven-flex-java-applications.htmlYes, I've read the comments and I saw the solution. But I have no file called weborb-services-config.xml, just the services-config.xml which is maybe the same one. But it's not working.
The init of the mapper is failing on the first call. On the second invoke, everything is fine. The function is called by a button click. And If I put the ActiveRecords.News.findAll() directly as dataprovider of a e.g. datagrid, everything works fine.
public function loadData():ArrayCollection
{
var responder:mx.rpc.Responder;
responder = new mx.rpc.Responder( gotData, gotError );
return ActiveRecords.News.findAll( responder );
}
That's my called function and the error is:
TypeError: Error #1009: Cannot access a property or method of a null object reference.
at weborb.messaging::WeborbMessagingClient/connect()[/Volumes/HD2/nightly_builds/wojava/build/tmp/weborbswc/weborb/messaging/WeborbMessagingClient.as:292]
at weborb.data::DataServiceClient$/subscribe()[/Volumes/HD2/nightly_builds/wojava/build/tmp/weborbswc/weborb/data/DataServiceClient.as:120]
at weborb.data::DataMapperProxy()[/Volumes/HD2/nightly_builds/wojava/build/tmp/weborbswc/weborb/data/DataMapperProxy.as:29]
at weborb.data::DataMapper()[/Volumes/HD2/nightly_builds/wojava/build/tmp/weborbswc/weborb/data/DataMapper.as:48]
at starchat.Codegen::_NewsDataMapper()
at starchat::NewsDataMapper()
at starchat.Codegen::_DataMapperRegistry/get News()[C:\development\projects\webOrbTest2\src\starchat\Codegen\_DataMapperRegistry.as:74]
at starchat::ActiveRecords$/get News()[C:\development\projects\webOrbTest2\src\starchat\ActiveRecords.as:34]
at webOrbTest2/loadData()[C:\development\projects\webOrbTest2\src\webOrbTest2.mxml:36]
at webOrbTest2/findAllCtl_clickHandler()[C:\development\projects\webOrbTest2\src\webOrbTest2.mxml:51]
at webOrbTest2/___webOrbTest2_Button1_click()[C:\development\projects\webOrbTest2\src\webOrbTest2.mxml:59]
Any solutions or ideas?
Thanks,
Paul