可以这样,image是个抽象类,不管用imge[]数组还是list
List
imgArr.Add(Image.FromFile("a.jpg", false));
imgArr.Add(Image.FromFile("a.jpg", false));
imgArr.Add(Image.FromFile("a.jpg", false));
System.Collections.IEnumerator itor = imgArr.GetEnumerator();
while (itor.MoveNext())
{
Console.WriteLine(((Image)itor.Current).RawFormat);//输出图片的格式
}
再加上:
PictureBox pb1 = new PictureBox();
pb1.Image = ims[0];
ps[0] = pb1;
建个list好了
list