I have a window with a ListBox on the left and a TextArea on the middle+Right (1/2 + 2/3).
Actually, if I enlarge the window, it is the ListBox that is enlarged (whatever left or right is moved with the window).
I was dreaming: is it possible to detectif the mouse is enlarging the window by the left / right ?
If yes, I wanted to let the ListBox grow (be larger) when the user enlarge the window placing the Mouse Cursor on the left (vertical) of the window and enlarge the TextArea if teh Mouse enlarge the window by its right (vertical) border.
Don’t lock the controls so they do not grow by themselves and modify the left+width Listbox when the window left has been changed in resize, or the TextArea right when resize has been done on the right. To obtain something like the lock effect, you can calculate the width based on the window expansion.
I think that I tried that yesterday evening (but I am not sure).
I may be bad thinking yesterday evening, I will try this afternoon.
Lock: All I remember was that I locked Top, Left, Bottom in both Controls.
For ListBox (window left expanding), I used TextArea1.Left - 20 (20 for the two margins around ListBox1).
I do not recall what I’ve done for TextArea1.
As I wrote above, I was not at 100% yesterday evening.
[quote=108320:@Emile Schwarz]Thank you Michel for your answer.
I think that I tried that yesterday evening (but I am not sure).
I may be bad thinking yesterday evening, I will try this afternoon.
Lock: All I remember was that I locked Top, Left, Bottom in both Controls.
For ListBox (window left expanding), I used TextArea1.Left - 20 (20 for the two margins around ListBox1).
I do not recall what I’ve done for TextArea1.
As I wrote above, I was not at 100% yesterday evening.[/quote]
If you leave controls locked, they will expand in ways you cannot control. So you want to unlock them at least left and right to get full control over that. Then you can keep ListBox.Left at 20 and TextArea.Width so the right stays at 20 from the right hand side edge of the window.