On May 24, 2006, at 7:03 PM, Chris Griffin wrote:
Has anyone worked out a way to do this? I have a control inside a
ContainerControl. That ContainerControl could be placed in another
control or a window. I need a generic way to work up the 'tree' to get
the global coordinates.
Here's the function I wrote:
Function UltimateLeft(extends container as ContainerControl) As integer
dim result as integer = container.left
// sum the left positions of all parents
while container.window isa ContainerControl
container = ContainerControl( container.window )
result = result + container.left
wend
return result
End Function
Do the same for top.
Asher
-------------------------
Asher Dunn
Head Developer, Fireye Software
http://www.fireyesoftware.com/
AIM, Yahoo, MSN: crazedglkid
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>