// image to byte[] Image photo = new Bitmap(selectPictureFile); System.IO.MemoryStream ms = new System.IO.MemoryStream(); photo.Save(ms, System.Drawing.Imaging.ImageFormat.Jpeg); byte[] imagedata = ms.GetBuffer(); // byte[] to image System.IO.MemoryStream ms = New IO.MemoryStream(imagedata) Bitmap b = new Bitmap(ms); //img = Drawing.Image.FromStream(ms)