img = new Image[picnum];
int k = 0;
foreach (KeyValuePair<int, string> kvp in myDictionary)
{
byte[] imagedata = System.Text.Encoding.Default.GetBytes(kvp.Value);
MemoryStream myStream = new MemoryStream(imagedata);
foreach (byte a in imagedata)
{
myStream.WriteByte(a);
}
img1= Image.FromStream(myStream);
myStream.Close();
k++;
}
集合里面value是放图片的二进制流
然后这边一直提示Image.FromStream(myStream);参数无效
想问是哪边错误?
还有就是有什么更好的方法
__innocence
相关分类