1Aug 08
You load an image from a stream, you then try to covert it to a byte array by loading it into another stream - BANG! Your 40.
Part of the improvements to Cropper was to save a thumbnail of the image in the CropSet file. This meant loading was dramatically improved as it didn't have to load the original and make a thumbnail each time.
However, it seems an image loaded using the FromStream method will keep the stream alive during the life time of the image (see link)
http://support.microsoft.com/Default.aspx?id=814675
So, attempting to save it to another stream will cause the Generic GDI+ error
.
The way around, as suggested by MS, is to create a copy of the image. They have given two ways of doing this, I don't know which is best, but I've chosen the first.
GDI+, Development