Converting Bitmap into array
Posted on 2004-09-12
I have this code:
Bitmap hBitmap = new Bitmap(imageList1.Images);
System.IO.Stream imgStream = new System.IO.MemoryStream();
byte buffer = new byte[imgStream.Length];
imgStream.Read(buffer, 0, (int) imgStream.Length);
While the retreiving of the image from the image list is good (I can set a picturebox image to hBitmap) the buffer is always empty. What am I missing?