Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: High
  • Security: Public
  • Views: 74
  • Last Modified:

ASP.NET : Maximum Report Limit Exceeded

Dear Experts,

Can anyone guide me on the error?

"Maximum report processing jobs limit configured has been reached"

I got the following code from the internet but I don't know where to use it. Please guide.

Imports System.Collections
Imports System.Collections.Generic
Imports System.Text
Imports CrystalDecisions
Imports CrystalDecisions.CrystalReports
Imports CrystalDecisions.CrystalReports.Engine

Namespace Test.Utilities
	Public Class ReportFactory
		Protected Shared reportQueue As New Queue()

		Protected Shared Function CreateReport(reportClass As Type) As ReportClass
			Dim report As Object = Activator.CreateInstance(reportClass)
			reportQueue.Enqueue(report)
			Return DirectCast(report, ReportClass)
		End Function

		Public Shared Function GetReport(reportClass As Type) As ReportClass

			'75 is my print job limit.
			If reportQueue.Count > 75 Then
				DirectCast(reportQueue.Dequeue(), ReportClass).Dispose()
			End If
			Return CreateReport(reportClass)
		End Function
	End Class
End Namespace

Open in new window


Regards,
D Patel
0
D Patel
Asked:
D Patel
  • 3
  • 2
2 Solutions
 
Dorababu MSenior DeveloperCommented:
0
 
D PatelD Patel, Software EngineerAuthor Commented:
That understood...

But how do I write code so that it clears the cache at 75 job reaches.

Where should I write the above code and from when do I call it?
0
 
Dorababu MSenior DeveloperCommented:
What I see is you need to do the following every time for crystal report

Load report,
Assign it to Viewer Control
Show Report in Viewer Control
Close Viewer Control and Unload (completely)
Then close/dispose/gc.collect outside of any viewer control code
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
D PatelD Patel, Software EngineerAuthor Commented:
I have applied the same to all pages where crystal report viewer control lies at Page_Unload event.

But still the issue is not resolved.
0
 
Pravin AsarCommented:
Also look at the timeout setting for the request. May be request is reaching limit

https://msdn.microsoft.com/en-us/library/system.net.httpwebrequest.timeout(v=vs.110).aspx
0
 
D PatelD Patel, Software EngineerAuthor Commented:
Thanks for your support.
0

Join & Write a Comment

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now