0

I have been working with a web application. It was running fun until I changed tables which were behind the app. I checked my code, and it looked fine to me. But I am keep getting this error, and not sure why. Can someone help?

[InvalidOperationException: Stack empty.]

System.Collections.Generic.Stack`1.Pop() +8625191

System.Web.UI.RenderTraceListenerList.EndRendering(TextWriter writer, Object renderedObject) +90

System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +12389839

System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5363

I think these two lines are causing the problem, but it worked fine before I adjust the typelist.

Context<TypedList> GetProductSearch(IPredicateExpression filter);
Context<TypedList> GetProductSearch(IPredicateExpression filter, ISortExpression sorter);
Community
  • 1
  • 1
002432SAM
  • 39
  • 7
  • 6
    Could you include the code that produces that error? – juharr Oct 16 '15 at 19:12
  • 4
    Apparently, `RenderTraceListenerList.EndRendering()` is popping the stack more than it should, i.e. it's calling `Stack.pop()` after it has already drained the stack. Look at the mentioned method an see what conditions there are for the call to `Stack.pop()`... – Albus Dumbledore Oct 16 '15 at 19:12

0 Answers0