I have a function which extracts a file into a byte array (data).
int contentLength = postedFile.ContentLength; byte[] data = new byte[contentLen
Any reason why you don't simply do this:
Image bitmap = Image.FromStream(postedFile.InputStream);