“/”应用程序中的服务器错误。

未将对象引用设置到对象的实例。

说明: 执行当前 Web 请求期间,出现未经处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。

异常详细信息: System.NullReferenceException: 未将对象引用设置到对象的实例。

源错误:


行 422:    using (TextReader reader = new StringReader(htmlc))
行 423:    {
行 424:        XMLWorkerHelper.GetInstance().ParseXHtml(writer, doc, reader);
行 425:    }
行 426:

源文件: e:\www\bx1.wskmn.com\index.aspx    行: 424

堆栈跟踪:


[NullReferenceException: 未将对象引用设置到对象的实例。]
   iTextSharp.tool.xml.html.table.Table.SetBorderAttributeForCell(Tag tag) +28
   iTextSharp.tool.xml.css.apply.HtmlCellCssApplier.Apply(HtmlCell cell, Tag t, IMarginMemory memory, IPageSizeContainable psc, HtmlPipelineContext ctx) +157
   iTextSharp.tool.xml.html.CssApplier`1.iTextSharp.tool.xml.html.ICssApplier.Apply(IElement e, Tag t, IMarginMemory mm, IPageSizeContainable psc, HtmlPipelineContext ctx) +107
   iTextSharp.tool.xml.html.CssAppliersImpl.Apply(IElement e, Tag t, IMarginMemory mm, IPageSizeContainable psc, HtmlPipelineContext ctx) +176
   iTextSharp.tool.xml.html.CssAppliersImpl.Apply(IElement e, Tag t, HtmlPipelineContext ctx) +20
   iTextSharp.tool.xml.html.table.TableData.End(IWorkerContext ctx, Tag tag, IList`1 currentContent) +171
   iTextSharp.tool.xml.html.AbstractTagProcessor.EndElement(IWorkerContext ctx, Tag tag, IList`1 currentContent) +90
   iTextSharp.tool.xml.pipeline.html.HtmlPipeline.Close(IWorkerContext context, Tag t, ProcessObject po) +372
   iTextSharp.tool.xml.XMLWorker.EndElement(String tag, String ns) +181
   iTextSharp.tool.xml.parser.XMLParser.EndElement() +111
   iTextSharp.tool.xml.parser.state.SelfClosingTagState.Process(Char character) +38
   iTextSharp.tool.xml.parser.XMLParser.ParseWithReader(TextReader reader) +247
   iTextSharp.tool.xml.parser.XMLParser.Parse(TextReader reader) +5
   iTextSharp.tool.xml.XMLWorkerHelper.ParseXHtml(PdfWriter writer, Document doc, TextReader inp) +438
   ASP.index_aspx.GeneratePDF(String pageTitle, String pageContent, String author, String subject, String keywords) in e:\www\bx1.wskmn.com\index.aspx:424
   ASP.<Site>d__9.MoveNext() in e:\www\bx1.wskmn.com\index.aspx:336
   System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) +99
   System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) +58
   System.Runtime.CompilerServices.TaskAwaiter`1.GetResult() +28
   ASP.<getsource>d__4.MoveNext() in e:\www\bx1.wskmn.com\index.aspx:235
   System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) +99
   System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) +58
   System.Runtime.CompilerServices.TaskAwaiter`1.GetResult() +28
   ASP.<PageLoadAsync>d__0.MoveNext() in e:\www\bx1.wskmn.com\index.aspx:189
   System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) +99
   System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) +58
   System.Web.UI.<ExecuteTasksAsync>d__3.MoveNext() +363
   System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) +99
   System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) +58
   System.Web.UI.<ProcessRequestAsync>d__554.MoveNext() +876


版本信息: Microsoft .NET Framework 版本:4.0.30319; ASP.NET 版本:4.7.3535.0