How to stretch Picture Box
Posted on January 5, 2009
1 2 3 4 5 6 7 8 9 10 11 12 13 | 'Graphics - How to stretch Picture Box Option Explicit 'Add two Picture Boxes to your form and add picture to Picture1 and add a Command Button to your form. 'This will stretch the first Picture Box to the size of the second Picture Box. Private Sub Command1_Click() Picture1.AutoSize = True Picture2.AutoRedraw = True Picture2.PaintPicture Picture1.Picture, 0, 0, Picture2.ScaleWidth, Picture2.ScaleHeight, 0, 0, _ Picture1.ScaleWidth, Picture1.ScaleHeight End Sub |