Private Function StretchImage(ByVal img As Image, ByVal sz As Size) As Image
Dim bmp As New Bitmap(sz.Width, sz.Height)
Dim g As Graphics = Graphics.FromImage(bmp)
g.DrawImage(img, New Rectangle(Point.Empty, sz), New Rectangle(Point.Empty, img.Size), GraphicsUnit.Pixel)
g.Dispose()
Return bmp
End Function
Me.PictureBoxx.Image = Me.StretchImage(My.Resources.img, Me.PictureBoxx.ClientSize)