Geeks With Blogs

AzamSharp Some day I will know everything. I hope that day never comes.

When creating lots of crystal reports you might get the error that "Maximum Reports have been generated and please contact the administrator". This is because of the registry settings for the Crystal Reports. I think the default maximum number of reports is between 70-80. Although you can change this by editing the registry but better technique is to close the and dispose the report when you are done with it.

You can close the report in the Page_Unload event of the page life cycle.

protected override void OnUnload(EventArgs e)



// close the report connection

this.Unload += new EventHandler(Report_Default_Unload);


void Report_Default_Unload(object sender, EventArgs e)


// close the report connection




The above code will ensure that the report object is closed and disposed and hence frees the memory.

Posted on Friday, September 15, 2006 1:54 PM | Back to top

Comments on this post: Maximum Reports have been generated error!

No comments posted yet.
Your comment:
 (will show your gravatar)

Copyright © Mohammad Azam | Powered by: | Join free