cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Read and Write protected memory issue

Former Member
0 Likes
478

Hi,

I have added a Crystal Report Viewer in my Custom Report page. I'm using Data Set as a data source. The page is loading fine with report data first time. I When i click the next page button it is started loading the report forever. I could not stop the loading. When i refresh the page i'm getting the following error message.

Attempted to read or write protected memory. This is often an indication that other memory is corrupt.

My page has 4 check boxes with different Report name. Based on the Report check box selection, first i'm loading the Data set then assigning into Crystal Report Viewer. First time the report loading fine(with the paging issue). When i select the next report check box and load the report, i'm getting the same error.

Please help me to fix this issue.

View Entire Topic
0 Likes

Known issue, Changes to the Standards now require you to move your code to the Page_init from Page_Load section.

Then it should all work.

Don

Former Member
0 Likes

I dont have code in Page_Load method. I have the following code in Page_Init method.

if (Session["CrystalReportSource"] != null)

{

   reportDocument = (ReportDocument)Session["CrystalReportSource"];

   CustomReportViewer.ReportSource = reportDocument;

}

Still it is not working.

Former Member
0 Likes

Have a peek at KBA 1985571 re. placing reports in session.

- Ludek

Senior Support Engineer AGS Product Support, Global Support Center Canada

Follow us on Twitter

Former Member
0 Likes

Thanks Ludek Uher.

My code is very much similar to what it was described in the link. Only difference is, I'm using data set as a source of report and I'm not using the Page_Unload() method.

Former Member
0 Likes

Dataset will not make a difference and using the exact code I have in the KBA, all works fine for me. See if placing the special field N of M on the report will work.

- Ludek

0 Likes

You can use Fiddler to trace what is happening also.

Are you doing anything with your Session object? Maybe the next report is not using the same session.

Can you attach a simple test app that emulates your main project so we can test and see what you are doing?

Don