We are running into a problem where our users will see a Null Reference Exception message ("Object reference not set to an instance of an object") when they switch to (or from) Print Preview mode after the report has "expired". Sometimes the report will expire because they waited too long (I think 20 minutes is the timeout on most of our servers) or if IIS happened to recycle while they were working on the report. For other operations (such as changing pages), the user gets a friendly message that says: "Report is unavailable or session has expired". It would be nice if they got a similiar friendly message in the Print Preview case.
We are on a slightly old version of Reporting but I've verified the bug is in the latest version (Q3 2014 SP1). We use the Silverlight report viewer.
To reproduce the problem, run a report. Then on the server you can execute the following method to clear out the cache (simulating IIS recycling or the session timing out):
private void ClearCache()
{
var cache = System.Web.HttpContext.Current.Cache;
var enumerator = cache.GetEnumerator();
while (enumerator.MoveNext())
{
cache.Remove((string)enumerator.Key);
}
}
Then when you go to Print Preview mode, you'll see the error. Screenshot attached.
We are on a slightly old version of Reporting but I've verified the bug is in the latest version (Q3 2014 SP1). We use the Silverlight report viewer.
To reproduce the problem, run a report. Then on the server you can execute the following method to clear out the cache (simulating IIS recycling or the session timing out):
private void ClearCache()
{
var cache = System.Web.HttpContext.Current.Cache;
var enumerator = cache.GetEnumerator();
while (enumerator.MoveNext())
{
cache.Remove((string)enumerator.Key);
}
}
Then when you go to Print Preview mode, you'll see the error. Screenshot attached.