cancel
Showing results for 
Search instead for 
Did you mean: 

The Position of UIElement

Former Member
0 Kudos

Hi all,

We have this situation.

When we want to popup a window in a view (for value help use), we would like to make the popup window just beside the button, but if we use IWDWindow.setPosition(left, top), we can not get the right position of the button. So in this way we can only provide an absolute position.

Have a look at the API of IWDView & IWDUIElement, we can not find any method deal with the position, is this mean there's no possible to get the position of any UIElement in a view?

What we need is just alignment.

Please help, thanks.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

William,

There is no way to get exact position of UI element on user screen.

There is an internal method used by EVS / OVS controls to position window relatively to InputField. However, this is internal method and it may not be used in custom applications.

Valery Silaev

SaM Solutions

http://www.sam-solutions.net

Answers (3)

Answers (3)

Former Member
0 Kudos

No available API for this function.

This is the result.

Hope next version can give an abstrctOVS class for custom configuration.

Former Member
0 Kudos

Hi William,

Unfornunately, this functionality is not available in webdynpro to position your popup relatively.

Regards,

Bhavik

vijayakhanna_raman
Active Contributor
0 Kudos

Hi,

Create a new window for this purpose. Its position can be controlled.

Check this code. 500 and 320 are the left and top positions.

IWDWindowInfo windowInfo = (IWDWindowInfo) wdComponentAPI.getComponentInfo().findInWindows("WND_PopupWindow");
IWDWindow window = wdComponentAPI.getWindowManager().createWindow(windowInfo, true);
window.setWindowPosition(500, 320);
window.setWindowPosition(WDWindowPos.RIGHT);
wdContext.currentContextElement().setVa_WindowRef(window);
window.open();

Regards,

Vijai