I have panel that has multiple pictureboxes which are added dynamically at runtime. The pictureboxes can be moved around the panel individually or as a user defined group. I want the user to be able to drag a mouse across the screen to "define" which pictureboxes are selected.
Basically I want to duplicate the VB6 or VS.Net design environment with regards to controls on a design time form. You can select multiple controls by dragging a rectangle around them then you can move the selected controls by either dragging them of using arrow keys. Of course my program will be doing this at runtime instead of design time.
I have every part working except Drawing the rectangle and based on that rectangle determining which picture boxes to select.
MOST IMPORT (and essential for full credit)
Tell me how to draw the dotted line rectangle so that is shows on top of the controls on the form while it is being drawn (mouse drag). It MUST be transparent so that you can see which pictureboxes will be selected.
Tell me any neat tricks you know for determing which controls to select based on the rectangle drawn.