Hi. I am having trouble with something I think should be fairly simple to fix.

I have a picturebox (its size doesn't matter).

I use pSet to randomly draw yellow pixels in it.

Let's say I end up having a square of 2 x 2 yellow pixels (VERY SMALL), I would then like the picturebox to be resized to exactly fits the pixels I've drawn into it.

The picturebox scalemode is set to pixels, and the autoredraw method doesn't seem to resize the picture box at all (it only does when I load up a .bmp in it).

I thought that "picLetter.width = 2" would have worked because the scalemode is in pixels.. but it doesn't.

VB Code:
  1. picLetter.AutoRedraw = True
  2.     picLetter.ScaleMode = vbPixels

Any tips?