Local Report hangs during SetParameter call in IIS6 Win Server 2003 RRS feed

  • Question

  • ASP.NET, report viewer executable SP1

    I am creating  reports with the local report object directly (ie, not using Report Viewer) as in the following code fragment:

    using Microsoft.Reporting.WebForms;
    localReport = new LocalReport();
    ReportDataSource myDataSource = new ReportDataSource("ds",ds);
    ReportParameter[] parms = new ReportParameter[1];
    parms[0] = new ReportParameter("myParam", paramValue);
    Warning[] warnings;
    string[] streamids;
    string encoding;
    string deviceInfo="<DeviceInfo><StartPage>0</StartPage></DeviceInfo>";
    string mimeType;
    string fileExtension;
    byte[] bytes = localReport.Render("PDF", deviceInfo, out mimeType, out encoding, out fileExtension, out streamids, out warnings);

    This code works 99% of the time, but about once every two weeks it hangs up during the SetParameters() call.  No exception is thrown.  After that happens once, it then fails for all users all 100% of the time until I do an IIS reset.  Looking at the Requests Executing paramater, each time someone tries to create a report a new request starts executing, and never stops, until the server gets overloaded.  An IIS reset is the only thing that helps.  Taking the app down with app_offline.htm does no good.

    I have tried a lot of things.  Went so far as to try running the report rendering in a new thread, so that I could then abort the thread if it didn't stop after a time, but that did not work either.. (the thread does not abort, and does not throw an exception)

    I have seen what I believe is the same issue discussed, without resolution, in this previous thread
    where it says this is because of a bug in report viewer..
    Has there been any progress towards a hotfix for report viewer, or any other workaround (other than not using IIS or Report Viewer)?

    Wednesday, June 13, 2007 3:37 PM

All replies