Link to home
Start Free TrialLog in
Avatar of Bharu
Bharu

asked on

How do i check whether any controls are laying over other controls.( ie, whether the controls are overlapped)

Hi'

My Problem is , i have many sets of static text boxes and edit  boxes in the dialog 1 beside the other. In some cases Edit boxes are laying over the static text boxes as they are very big.. I want to show the Tooltip (as complete name of the static text) for static text boxes only if they are overlapped by edit boxes..

How do i check this..Pls give me if u have any ideas

regs

 
Avatar of AndyAinscow
AndyAinscow
Flag of Switzerland image

Either make an array with your statics that are overlaid by hand or in the OnInitDialog code a routine to check each child window in turn if it is overlain by another control.  Check the window rect of each and see if the two rectangles have a common area.

OnMouseMove message - see if the control it is over is one of these in your array, if it is then pump the ToolTip to display.
Avatar of Bharu
Bharu

ASKER

Hi Andy,
they are created dynamically.
ASKER CERTIFIED SOLUTION
Avatar of AndyAinscow
AndyAinscow
Flag of Switzerland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial