cancel
Showing results for 
Search instead for 
Did you mean: 

PopUp Window instance is not getting destroyed on click of OK Button.

Former Member
0 Kudos

Hi Friends,

In my Application i have two Input Fields.

When ever i dont enter any data into those fields i get a PopUp Window "Please enter the Fields" and i have an OK Button.

When i Click on this OK Button the Window instance must be Destroyed.

But i am unable to do so.Instead when i Click on OK Button that particular Window Instance gets hanged Up,and hence i am struck there.

Then i need to refresh the page.

Please help me out to find a solution for this issue.

Thanks and regards,

Chandrashekar.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi

Follow the steps

In your current view where you create your Popupwindow; create a model attribute name "popWin" of type IWDWindow;

In code;after creating the popup window assign window object to the context element


IWDWIndow window = WDComponentAPI.getWindowManager().createWindow( WindowInfo, true);
wdContext.currentContextElement.setpopWin( window);

At the Popup window view; create a model attribute name popWin of type IWDWindow and map it with the one that created before.

set the code on btnaction


IWDWindow popwin = (IWDWindow)wdContext.currentContextElement().getPopWin();
popwin.destroyInstance();

This will work

Regards

- Vinod

Edited by: Vinod V on Mar 3, 2008 7:21 PM

Former Member
0 Kudos

Hi,

Why do you require a window for displaying a validation message. Use Confimation dialog instead.

Are you sure that you are setting the window instance to an attribute while creating the window and destroying the same.

thanks & regards,

Manoj

Former Member
0 Kudos

Hi Manoj,

I am very much sure that i am setting the window instance to an attribute while creating the window and destroying the same.

But i am unable to do the same.

Please let me know.

Thanks and regards,

Chandrashekar.

Former Member
0 Kudos

Hi,

Could you please post the code that you have written for closing the window and as well as that for creating the window.

thanks & regards,

Manoj