This is a migrated thread and some comments may be shown as answers.

Render() Exception Handling

7 Answers 237 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Tom
Top achievements
Rank 1
Tom asked on 14 Jan 2009, 07:18 PM
I haven't found any documenation regarding exception handling for exceptions thrown during the Render() process that are are not bubbled up.  While rendering, the Render() method does not throw theTelerik.Reporting.Processing.Expressions.InvalidExpressionException.  Instead a report is returned (with the "red box" in-place of the invalid element) and no exception occurs.  I'd like to catch these types of processing/rendering exceptions so invalid reports are not created.  Thoughts?

7 Answers, 1 is accepted

Sort by
0
Steve
Telerik team
answered on 15 Jan 2009, 01:51 PM
Hello Tom,

Currently we have decided not to break the rendering and show the error in the respective item/section, instead of throwing app exception. However we would be glad to hear your opinion on why would you need this behavior changed and we would consider what can be done on our end.

Sincerely yours,
Steve
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Tom
Top achievements
Rank 1
answered on 15 Jan 2009, 04:16 PM
Steve,

Thanks for replying.  I think there's a simple and straight-forward answer...  
Test-driven development (TDD)  and automated testing using NUnit and such are very popular these days.  In this specific scenario, using an integrated unit test project in Visual Studio 2008 does not catch mis-coded report expressions.  My implementation has some variances in the xml data source and since I'm producing 100,000+ PDF reports per month, automated testing helps identify problems with the report definition and/or databinding while accepting a large sampling of data.  The "internal" errors thrown during the render process are crucial for automated testing.

I'm thinking a static bool that will suppress the thrown errors would solve the problem for the developer:


Telerik.Reporting.Processing.
ReportProcessor .SuppressExceptions = true; (default)

Thanks you,
Tom

 

 

 

 

 

 

0
Accepted
Svetoslav
Telerik team
answered on 15 Jan 2009, 05:42 PM
Hello Tom,

Thank you for the explanation. You have a valid point and we will definitely have it in mind while working on the next release. Since we need some time to investigate the possible solutions, I have logged your suggest in our TODO list.

Your Telerik points have been updated as a token of gratitude. Do let us know if other ideas come to mind.

Greetings,
Svetoslav
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Michele
Top achievements
Rank 2
answered on 30 Aug 2010, 08:12 AM
Hello,
excuse me, has the exception notification been implemented? I'm generating a large number of reports (almost 20,000) and I can't check each file if has been rendered correctly...
Thanks
Paolo
0
Milen
Telerik team
answered on 02 Sep 2010, 09:31 AM
Hi Paolo,

Yes, the error handling mechanism is implemented since version 2009 Q2 of Telerik Reporting. You need to handle the ReportProcessor.Error event in order to be notified when an error occurs.

Hope this information helps.

Best wishes,
Milen
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Michele
Top achievements
Rank 2
answered on 03 Sep 2010, 08:21 AM
Hello,
with the SL reportviewer I've to check for the Error property?... I don't see an Error event...
Thanks

Paolo
0
Steve
Telerik team
answered on 03 Sep 2010, 05:17 PM
Hello Paolo,

There is no error event for the viewer's themselves. You should use the error event of the ReportProcessor class as specified by my colleague with a link to the API reference.

Kind regards,
Steve
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
General Discussions
Asked by
Tom
Top achievements
Rank 1
Answers by
Steve
Telerik team
Tom
Top achievements
Rank 1
Svetoslav
Telerik team
Michele
Top achievements
Rank 2
Milen
Telerik team
Share this question
or