Flex Builder:找不到 ManagedQuery 或 ManagedOperation
这是对我收到的问题/错误的答复,但我不知道如何实现它,有人可以帮助我解决这个问题吗?
事实证明,我的问题是由于同一页面中使用的两个不同组件中有同一数据服务类的两个实例引起的。如果我更改组件以共享数据服务的同一实例,那么一切都会正常工作。
如何在主应用程序或其他地方定义可以在组件之间共享的服务?
组件A:
<s:CallResponder id="getTblsupplierByIDResult"
result="getTblsupplierByIDResult_resultHandler(event)"/>
<tblsupplierservice:TblsupplierService
id="tblsupplierService"
fault="Alert.show(event.fault.faultString + '\n' + event.fault.faultDetail)"
showBusyCursor="true"/>
组件B:
<s:CallResponder id="getAllTblsupplierByUserResult"/>
<tblsupplierservice:TblsupplierService
id="tblsupplierService"
fault="Alert.show(event.fault.faultString + '\n' + event.fault.faultDetail)"
showBusyCursor="true"/>
Wim
This is the response to my question/error I get, but I don't know how to implement it, is there someone who can help me out with this one?
It turns out that my issues were caused by having two instances of the same data service class in two different components that were used in the same page. If I changed the components to share the same instance of the data service, then everything works just fine.
how to define a service in the main application or elsewhere which can be shared between components?
Component A:
<s:CallResponder id="getTblsupplierByIDResult"
result="getTblsupplierByIDResult_resultHandler(event)"/>
<tblsupplierservice:TblsupplierService
id="tblsupplierService"
fault="Alert.show(event.fault.faultString + '\n' + event.fault.faultDetail)"
showBusyCursor="true"/>
Component B:
<s:CallResponder id="getAllTblsupplierByUserResult"/>
<tblsupplierservice:TblsupplierService
id="tblsupplierService"
fault="Alert.show(event.fault.faultString + '\n' + event.fault.faultDetail)"
showBusyCursor="true"/>
Wim
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我相信我让它工作的唯一方法是在主根应用程序中包含 xmlns 声明、服务声明和 callresponder 声明,以便这是创建的第一个实例,并且所有子组件都与第一个实例相关。
如果它有效,请告诉我,因为我对这种托管数据有很多问题。
The only way I got this to work I believe is to include an xmlns declaration, service declaration and callresponder declaration in the main root Application so that this is the firsat instance created and all sub components relate to this first instance.
If it works let me know, as I have many problems with this sort of Managed Data thing.