cancel
Showing results for 
Search instead for 
Did you mean: 

Size of popup window

Former Member
0 Kudos

Hello All,

I have two windows

1. LaunchPad Window

2. PopUpWindow

I need to set the height & width of PuPUpWindow to be some percentage of main window. How this can be done?

I dont want to use absolute integers because different computers may have different resolutions...

<b>Here is my code:</b>

	IWDWindowInfo myWinInfo = wdComponentAPI.getComponentInfo().findInWindows("PopUpWindow");
	final IWindow wndMain = TaskBinder.getCurrentTask().getApplicationWindow(); 
	IWDWindow myPopupWindow = wdComponentAPI.getWindowManager().createModalWindow(myWinInfo);
  	myPopupWindow.setWindowPosition(WDWindowPos.CENTER);
 	myPopupWindow.setWindowSize(800,500);
  	myPopupWindow.show();

Regards,

Aayush

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Aayush Dubey

 
final IWDWindow myPopupWindow = <>;
/* EM is relative to font size */
/* so result is better then with PX */
myPopupWindow.setWindowSize
( 
  new WDCssSize(200, WDWindowUnitOfLength.EM), 
  new WDCssSize(100, WDWindowUnitOfLength.EM) 
);

Play with WDWindowUnitOfLength: there are also PER_CENT constant, but I've never try it for windows.

Valery Silaev

EPAM Systems

http://www.NetWeaverTeam.com/

Former Member
0 Kudos

Hi Aayash,

I dont think it can be done .You will have to specify using pixels

Regards,

Rohit