【发布时间】:2016-12-06 12:20:34
【问题描述】:
以下是我保存图像的代码,
HttpPostedFile postedFile = request.Files[file];
string directoryPath = @"~\PostImage\";
Image image = Image.FromStream(postedFile.InputStream);
string Filepath = Server.MapPath(directoryPath);
string Filename = Filepath + "PostImageFile.jpg";
result.FieldName = Filename;
image.Save(Filename, ImageFormat.Jpeg);
image.Save(Filename, ImageFormat.Jpeg); 出现错误
【问题讨论】:
标签: asp.net-mvc-4 c#-4.0