The PlusWnd::GetElementPos function returns the X position, Y position, width or height of the specified element. To get the position of a control instead, call the GetWindowRect API function.
[number] GetElementPos( [string] ElementId, [number] PosInfo );
[enum] Requested
property of the element,
represented by a number taken from the following enumeration:
POSINFO_X (1)
POSINFO_Y (2)
POSINFO_WIDTH (3)
POSINFO_HEIGHT (4)Position on the X axis
Position on the Y axis
Width of the element
Height of the element
A number containing the property requested in PosInfo. Values are all expressed in pixels and are client coordinates relative to the upper-left corner of the window.
This function typically fails for the following reason:
This function is particularly useful when adding a PlaceHolderElement element in your window to create things like child windows. It helps find the appropriate position and size to use as elements are best declared, like controls, with dialog units instead of pixel units.
Object | PlusWnd |
---|---|
Availability | Messenger Plus! Live 4.60 |