Click here to Skip to main content
15,394,578 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi,

I am using Report Viewer control in web application.[ReportViewer version 11].The applications sessionstate mode is set to InProc as follows
<sessionState mode="InProc" cookieless="false" timeout="20" /> [I cannot change the sessionstate mode and cookiless properties]
The report viewer is running with multiple worker process. I have implemented IReportServerConnection interface. I am passing username, password, domain name and server url via web config file to IReportServerConnection interface.
When I click on a button and try to connect to the SSRS report server to fetch data, I get ASP.Net session has expired or could not be found error message on reportviewer control.

Web.config file entries are as below.
XML
<assemblies>
  <add assembly="Microsoft.ReportViewer.Common, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91" />
   </assemblies>
<httpHandlers>
  <add verb="*" path="Reserved.ReportViewerWebControl.axd" type = "Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91" />
</httpHandlers>
<handlers>
     <add name="ReportViewerWebControlHandler" preCondition="integratedMode" verb="*" path="Reserved.ReportViewerWebControl.axd" type="Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91" />
</handlers>


Please help out as soon as possible.

Thank You in advance.

Regards,
Rajkumar Vishwakarma
Posted
Updated 17-Jun-22 4:23am
v2

You cannot use sessionState mode="InProc" if you use more than one Worker Process because every worker process would keep track on their own set of sessions.

Either use only one worker process or change sessionState mode to use either a stateservice or a database.
   
Comments
Member 9903636 16-Jan-14 22:16pm
   
where we should have Worker process ?
If it's in IIS than we have 1 and it's running in SSL(Load balancing).

Regards,
Rajkumar
Jörgen Andersson 17-Jan-14 2:39am
   
If you are using more than one server you are also effectively using more than one worker process, and then you cannot use sessionState mode="InProc".
One way to fix the problem is to start the "ASP.NET State Service" on ONE of the servers and point all servers to use that servers StateService.
Member 9903636 17-Jan-14 2:46am
   
i cannot change sessionState mode because my whole application is running on that and this issue even in local development server also.

My application working fine, only in reportviewer i m getting this issue.


Regards,
Rajkumar
Jörgen Andersson 17-Jan-14 2:49am
   
Then you will HAVE to use only one workerprocess, and of course only ONE server.
Member 9903636 17-Jan-14 2:53am
   
i m using 1 workerprocess in IIS and for local development i have only 1 server
Jörgen Andersson 17-Jan-14 2:59am
   
In your original post you state: "The report viewer is running with multiple worker process", this setting is incompatible with "sessionState mode="InProc""
Member 9903636 17-Jan-14 4:30am
   
IIS have multiple worker process in production, but i m facing same issue in local development also.

I had tried almost 20 to 25 solution for resolving this issue but enable to resolve.

help me, it's urgent project.

Regards,
Rajkumar
Member 9903636 17-Jan-14 4:35am
   
i want to attach error in code project site, but enable to find attachment button.
Jörgen Andersson 17-Jan-14 5:59am
   
There is no attachment possibility for several reasons including spam. Cut and paste the error message into your original post or use tinypic or something similar.
Member 9903636 17-Jan-14 6:33am
   
SSRS error Log

library!ReportServer_0-36!33c0!01/16/2014-18:11:02:: i INFO: RenderForNewSession('/GBL_QA/Case_Load_as_Today_Grouped_By_CaseManager')
webserver!ReportServer_0-36!33c0!01/16/2014-18:11:10:: i INFO: Processed report. Report='/GBL_QA/Case_Load_as_Today_Grouped_By_CaseManager', Stream=''
processing!ReportServer_0-36!9d74!01/16/2014-18:11:52:: e ERROR: Throwing Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: , Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: There is no data for the field at position 4.;

but when i refresh same page from browser than i m getting records.

Regards,
Rajkumar
Member 9903636 21-Jan-14 7:26am
   
still i am facing same problem with SSRS report
Adding KeepSessionAlive="false" in ReportsViewer control fixes this issue.
   

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900