Most controls in a DataWindow object - column, compute, text, etc. - have .Moveable and .Resizeable properties (misspelled in the DW painter BTW). When these are enabled, then the user, as expected, can move and resize the controls at runtime. Is there an event, custom or otherwise, where I can trap whenever this moving or resizing occurs?
Won't the RESIZE event in the DW capture the change in size when a user resizes the dw?
When the user moves an object, they always use the MOUSE. Therefore I'd put code in the LBUTTONUP event of the datawindow and check for the X and Y positions.
1. Capture the X and Y positions when you open the DW, and set those values in ll_Current_x and ll_current_y;
then set ll_prev_x = 0 and ll_prev_y = 0
In the LBUTTONUP event check the current X and Y against the ll_current_X and ll_current_Y values, and if they are different, then reset your variables and you know the control has been moved.
HI, Ronnie -
I think the best you can do is check the DataWindow.Syntax.Modified property in the LButtonUp event. If "yes" is returned, something in the DW's internal structure/layout has changed. Of course, this property can also become "yes" if sorting or filtering has changed, so it's not a slam dunk.
- John Fauss
- Tuesday, 2 August 2022 21:07 PM UTC
- Page :
However, you are not allowed to reply to this question.