Encapsulated Select Box Code

Forms and Controls

Version Compatibility: Visual Basic 6

More information:
This is a sample of how to code a procedure so it will fit into any application with ease. Paste the drawselect procedure into you app and In all the graphic controls in your project add this call to the MouseDown Event:
DrawSelect "Down", frmSelBox, X, Y
and this call to the mousemove event:
If Button = 1 Then DrawSelect "Move", frmSelBox, X, Y
This will allow the user to draw a selection box on any graphic control. The attached demo has a picture box on a form drag a select box on each, simple!

Instructions: Click the link below to download the code. Select 'Save' from the IE popup dialog. Once downloaded, open the .zip file from your local drive using WinZip or a comparable program to view the contents.

Download selbox.zip