Returns an item's size and location.
Syntax
Rect = Send_Message(Ctrl, "OLE.GetItemRect", Item)
Parameters
Parameter | Description |
---|---|
Item | The item whose rectangle to get. |
Returns
The item's size and location.
Remarks
The GetItemRect method returns the size and location of the given item. The Item parameter must be a key to a valid item. If the item is currently in view, then it's rectangle is returned. If the item is not in view, then "" is returned. The returned value uses the same multivalue structure as the standard OpenInsight SIZE property:
Pos | Name | Type | Description |
---|---|---|---|
<1> | X | Integer | The item's x position |
<2> | Y | Integer | The item's y position |
<3> | Width | Integer | The item's width |
<4> | Height | Integer | The item's height |
The position of the item is relative to the upper left corner of the SRP Tree Control's client area.
Example
// Get Item's rectangle ItemRect = Send_Message(@Window:".OLE_TREE", "OLE.GetItemRect", "Item1")