cancel
Showing results for 
Search instead for 
Did you mean: 

Popup

Former Member
0 Kudos

Hi,

I am creating a popup using this code :

	IWDWindowInfo myWinInfo = wdComponentAPI.getComponentInfo().findInWindows("WindowName");
	IWDWindow myPopupWindow = wdComponentAPI.getWindowManager().createWindow(myWinInfo,true);
	myPopupWindow.setWindowPosition(500,500);
	myPopupWindow.open(); 

I need to come out of this popup when i click on a button in this popup.

Can someone tell me how to do that??

Thanks,

Sneha Singh.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Do you need create an attribute in a context of custon controller. Ex: windowPopup. Then you map this attribute with principal view and popup view.

Put this code to open popup:


	IWDWindowInfo myWinInfo = wdComponentAPI.getComponentInfo().findInWindows("WindowName");
	IWDWindow myPopupWindow = wdComponentAPI.getWindowManager().createWindow(myWinInfo,true);
	myPopupWindow.setWindowPosition(500,500);
	myPopupWindow.open(); 
wdContext.currentContextElement().setWindowPopup(myPopupWindow);

And this code to close popup:


IWDWindow myPopupWindow = wdContext.currentContextElement().getWindowPopup();
myPopupWindow.destroy();

Former Member
0 Kudos

Thanks a lot Edson.

Answers (0)