views:

294

answers:

1

We have the VS 2005 version of the ReportViewer control on an ASP.NET page. The reports are executed against SQL2008 Reporting services and display correctly. We have Interactive Sorting on the columns which works as expected...usually.

On larger result sets (over 100 pages), the sort stops, displays a white background in the viewer with the words, "The operation has timed out". The ironic part is that it does this in about 3 seconds. I thought I had it when I saw that the ServerReport.Timeout is 2000 ms by default, but changing that to 30,000 ms did not make a difference. It's like it doesn't even have the will to try sorting that much data :) Here's the code:

        var rvMain = new ReportViewer {
            EnableViewState = true,
            ProcessingMode = ProcessingMode.Remote,
            ShowRefreshButton = false,
            AsyncRendering = true,
            ShowCredentialPrompts = false,
            ShowDocumentMapButton = true,
            DocumentMapCollapsed = true,
        };
        rvMain.ServerReport.DisplayName = displayName;
        rvMain.ServerReport.ReportPath = reportPath;
        rvMain.ServerReport.Timeout = 30000;

I have looked at many of the other posts on various timeouts. However, this ONLY HAPPENS WHEN SORTING, and then only on large result sets. Any suggestions would be appreciated!!

UPDATE: The sort does not timeout when the sort is done on the report running directly in SQL Report Manager web site.

+2  A: 

Looks like we got ourselves into this one. We implemented IReportServerConnection2[1] because we are not using session state and we wanted to control the credentials used to connect to the Reporting Service. In that interface implementation, we had an unusual default of 2000 ms. So, on the round trip that occurs with interactive sort, it was using that default instead of the value set on the initial ReportViewer creating. Obviously raising the value of Timeout in the implementation of IReportServerConnection2 fixed it.

Randy Eppinger

related questions