2台服务器我在服务器A上装一个windows services,负责从数据库中读取图片二进制流,然后用以下方式写入到服务器B上
using(MemoryStream ms = new MemoryStream(Convert.FromBase64String(data))) {
Image i = Image.FromStream(ms);
i.Save(this.m_AimPath,System.Drawing.Imaging.ImageFormat.Jpeg);
}报异常
System.Runtime.InteropServices.ExternalException: GDI+ 中发生一般性错误。经分析:
1.在若不是写入服务器B,而是写本机,没有问题,图片写成功
2.若是写成winform程序,可以成功拷贝到服务器B就是windows services不行.
怀疑是权限问题,但不知怎么解决.
各位可有类似经历?