string file = "D:\\QQ截图20141205121451.png"; //new一个Image实例,并读取图片 System.Drawing.Image insusImage = System.Drawing.Image.FromFile(file); //实例就可以取得宽度与高度了。 Response.Write(insusImage.Width.ToString()+" "+insusImage.Height.ToString()); return;
时间: 2024-10-13 04:48:43