‘/ jobnumber’应用程序中的服务器错误:
A generic error occurred in GDI+.
Description: An unhandled exception
occurred during the execution of the
current web request. Please review the
stack trace for more information about
the error and where it originated in
the code.
例外细节:
System.Runtime.InteropServices.ExternalException: A generic error occurred in GDI+.
来源错误:
An unhandled exception was generated
during the execution of the current
web request. Information regarding the
origin and location of the exception
can be identified using the exception
stack trace below.
堆栈跟踪:
这通常表示Web用户(例如IIS_USR)无权使用[ExternalException (0x80004005): A
generic error occurred in GDI+.]
System.Drawing.Image.Save(String
filename, ImageCodecInfo encoder,
EncoderParameters encoderParams)
+377518 System.Drawing.Image.Save(String
filename, ImageFormat format) +69
System.Drawing.Image.Save(String
filename) +25
Assignment.CreateBitmapImage(String
sImageText, Image Image1, JobInfo
job_info_param) +124
Assignment.PrintButton_Click(Object
sender, EventArgs e) +271
System.Web.UI.WebControls.Button.OnClick(EventArgs
e) +111
System.Web.UI.WebControls.Button.RaisePostBackEvent(String
eventArgument) +110
System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String
eventArgument) +10
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler
sourceControl, String eventArgument)
+13 System.Web.UI.Page.RaisePostBackEvent(NameValueCollection
postData) +36
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean
includeStagesAfterAsyncPoint) +1565
将任何数据保存到您在Web服务器上保存位图的文件夹中.
我之前遇到过类似的问题.检查服务器上该文件夹的访问权限.首先让每个人都可以完全访问该文件夹(只是为了确保问题),然后再将其缩小,以便只有所需的用户才能访问.