0
votes

I created SSRS report in dynamics AX 2012 with DataProvider Class.

When i open report in AX report viewer window everything works, but problem is when i try to generate print preview or send report directly to the printer.

i get exception:

Microsoft.Dynamics.AX.Framework.Reporting.Shared.ReportException: An error occurred rendering the report. Error message: The report execution 4ra2ylaiam4azjy1phpihni3 has expired or cannot be found. (rsExecutionNotFound)
   at Microsoft.Dynamics.AX.Frameworks.Controls.ReportViewer.ServerReportAdapter.RenderReportViaURLAccess(Int32 startPage, Int32 endPage)
   at Microsoft.Dynamics.AX.Frameworks.Controls.ReportViewer.ServerReportAdapter.RenderReportMetafiles(Int32 startPage, Int32 endPage)
   at Microsoft.Dynamics.AX.Frameworks.Controls.PrintPreview.AxPrintPreviewControl.printPreviewPanel_Paint(Object sender, PaintEventArgs e)
   at System.Windows.Forms.Control.OnPaint(PaintEventArgs e)
   at System.Windows.Forms.Control.PaintWithErrorHandling(PaintEventArgs e, Int16 layer)
   at System.Windows.Forms.Control.WmPaint(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

On print preview window appears red cross only.

Any idea? help me, please :)

1

1 Answers

0
votes

In my case the problem reason was report parameter with type "DECIMAL". After replacing/converting it to "string" (in AX side and in SSRS side) - problem was solved.

It was Standart AX 2012 Report: AssetExploatiation