on 12-17-2007 4:36 PM
I am getting the following exception when I trying to go to Details view from my results view.
com.sap.tc.webdynpro.services.exceptions.WDRuntimeException: Instance of view controller ResultsView does not exist.
at com.sap.tc.webdynpro.progmodel.controller.Component.getController(Component.java:356)
at com.sap.tc.webdynpro.clientimpl.html.client.HtmlClient.handleUIElementEvent(HtmlClient.java:832)
at com.sap.tc.webdynpro.clientimpl.html.client.HtmlClient.updateEventQueue(HtmlClient.java:763)
at com.sap.tc.webdynpro.clientserver.cal.AbstractClient.initEvents(AbstractClient.java:131)
at com.sap.tc.webdynpro.clientserver.cal.AbstractClient.prepareTasks(AbstractClient.java:99)
at com.sap.tc.webdynpro.clientserver.cal.ClientManager.doProcessing(ClientManager.java:250)
at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doWebDynproProcessing(DispatcherServlet.java:154)
at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doContent(DispatcherServlet.java:116)
at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doPost(DispatcherServlet.java:55)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:390)
at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:264)
at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:347)
at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:325)
at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:887)
at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:241)
at com.sap.engine.services.httpserver.server.Client.handle(Client.java:92)
at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:148)
at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)
at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
at java.security.AccessController.doPrivileged(Native Method)
at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)
at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)
To explain further, I have 3 views in my webdynpro project, list view, results view and detail view that is embedded in the same window.
In the list view, I have a table of materials with linktoaction event that when clicked will go to detail material view to display material information. In this scenario this is working with no problems for all the items in the list.
When I do the same thing from the result view as the list view, only the first url link action works to display the detail view , the others fail with the above exception.
Any help on resolving this issue is appreciated.
Thanks,
Sunitha.
Hi,
Can you post the code what you are doing in the action handlers.
Can you check the lifespan of this view[ResultView]
Regards
Ayyapparaj
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Ayyapparaj,
The lifespan of ResultsView is "FrameworkControlled".
Following is the code snippet for onclick of a row in the table in the results view,
IWDMessageManager messageMgr = wdThis.wdGetAPI().getComponent().getMessageManager();
// getting the user's assigned SoldTo from the UME profile
String[] customer = null;
String SoldTo = null;
try
{
IUser user = WDClientUser.getLoggedInClientUser().getSAPUser();
IUserAccount[] acct = user.getUserAccounts();
customer = user.getAttribute(AvailabilityApp.NAMESPACE_LENNOX,AvailabilityApp.ATTR_SOLDTO);
SoldTo = customer[0];
} catch (UMException e)
{
// TODO Auto-generated catch block
messageMgr.reportException(e.getMessage(),false);
}
//create the instance and pass parameters for RFC Z_RFC_HRP_MATERIAL_INFO_Input
Z_Rfc_Hrp_Material_Info_Input input = new Z_Rfc_Hrp_Material_Info_Input();
wdContext.nodeZ_Rfc_Hrp_Material_Info_Input().bind(input);
input.setMatnr(wdContext.currentATP_To_AtpElement().getMatnr().toUpperCase());
input.setUser_Id(SoldTo);
//executing the RFC Z_Rfc_Wwhc_Zatp
wdThis.wdGetAvailabilityAppController().ExecuteZ_RFC_HRP_MATERIAL_INFO();
wdContext.currentContextElement().setReturnTextDisplay("Availability Results");
wdThis.wdFirePlugToDetailView();
When it goes to Detail view and try to display the UI bound to the output from the above
Z_RFC_HRP_MATERIAL_INFO() , it shows this error.
Please note that the above code does not fail for the first row of the results table in the results view, but it does for all the others. Is there something that I am missing here ?
Thanks,
Sunitha.
Yes, I do call Invalidate() method after executing the rfc. I have the bapi nodes in the controller instance and then map the nodes to the view instances.
Following is the code of the BAPI execution.
try {
wdContext.currentZ_Rfc_Hrp_Material_Info_InputElement().modelObject().execute();
wdContext.nodeMat_Info_Output().invalidate();
} catch (WDDynamicRFCExecuteException ce) {
msgMgr.reportException(ce.getMessage(), false);
}
finally{
//If connection is still alive after RFC execution, close it.
wdContext.currentZ_Rfc_Hrp_Material_Info_InputElement().modelObject().modelInstance().disconnectIfAlive();
}
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.