Alex, Try using a label control (with a border) instead of a rectangle. This will avoid the Z-order issues.
Also, when I implemented the same thing, I used individual label controls for each grab handle (with ForeColor and BackColor set to Black), and controlled their movement and that of the box manually. It was easy, once I got the hang of using delegates for the events. Bill On Wed, 17 Apr 2002 08:15:04 -0700, Alex Yakhnin <[EMAIL PROTECTED]> wrote: >Hi All, > >I am creating a kind of a form designer and trying to emulate moving the >control during the design time on the form by drawing the rectangle, but >the rectangle is allways drawn behind the control. I am using the Graphics >object from the form and even tried to use the DrawRectangle and >ControlPaint.DrawGrabHandle. > >Thanks... Alex > >You can read messages from the DOTNET archive, unsubscribe from DOTNET, or >subscribe to other DevelopMentor lists at http://discuss.develop.com. You can read messages from the DOTNET archive, unsubscribe from DOTNET, or subscribe to other DevelopMentor lists at http://discuss.develop.com.