Autoredraw simillar property

  • Thread starter Thread starter XY
  • Start date Start date
X

XY

I've noticed that neither forms nor picture boxes have
the autoredraw property anymore in VB .NET. What
substitute is there for it? What lines of code should i
write to grant the form or the picture box this property?
 
Hi,

Draw on a bitmap and set the pictureboxes image to the bitmap

Dim bm As New Bitmap(PictureBox1.Width, PictureBox1.Height)

Dim g As Graphics = Graphics.FromImage(bm)

Dim rDraw As New Rectangle(0, 0, bm.Width, bm.Height)

g.Clear(Color.Blue)

g.FillEllipse(Brushes.Red, rDraw)

g.Dispose()

PictureBox1.Image = bm



http://www.bobpowell.net/picturebox.htm



Ken
 
Back
Top