Hi,
I have created a web dynpro application like this: a first window with a button that calls a popup with user info and telephone number and a button OK.
When I click on OK, the popup window close perfectly, but if I click again on the button of the first page to see again the popup, I get a null pointer exception error:
The initial exception that caused the request to fail, was:
java.lang.NullPointerException
at com.sap.tc.webdynpro.clientserver.window.ApplicationWindow.handle(ApplicationWindow.java:258)
at com.sap.tc.webdynpro.clientserver.window.ApplicationWindow.handleWindowEvents(ApplicationWindow.java:239)
at com.sap.tc.webdynpro.clientserver.cal.AbstractClient.executeTasks(AbstractClient.java:149)
at com.sap.tc.webdynpro.clientserver.session.ApplicationSession.doProcessing(ApplicationSession.java:321)
at com.sap.tc.webdynpro.clientserver.session.ClientSession.doApplicationProcessingStandalone(ClientSession.java:713)
The popup code:
IWDWindow myPopup = wdContext.currentPopupNodeElement().getPopupAttribute(); if (myPopup == null) { IWDWindowInfo windowInfo = wdComponentAPI.getComponentInfo().findInWindows("PopWin"); myPopup = wdComponentAPI.getWindowManager().createModalWindow(windowInfo); myPopup.setWindowPosition(200, 200); wdContext.currentPopupNodeElement().setPopupAttribute(myPopup); wdContext.currentPopupNodeElement().setUserName("thibault"); wdContext.currentPopupNodeElement().setUserTelNumber("01010101"); } myPopup.show();
The close function for the popup:
IWDWindow window = wdContext.currentPopupNodeElement().getPopupAttribute(); window.hide(); window.destroyInstance();
Has any one got any solution, I would really appreciate your help.
Thibault Schalck