Use Telerik RadControls For WP's RadDiagnostics to Enable Users to Find Bugs

 I know that this title is a little provocative; that is my intention. And of course I will tell you why.

I am participating in several betas for Windows Phone apps. I know some of the developers from Twitter, and had several conversations about diagnosing and fixing bugs. In the end, developers all have one goal: a buttery-smooth running application without any bugs.

Some of the betas I use also use Telerik RadControls. They enable developers to easily create awesome apps without writing the controls from the ground up. On top, we are able to customize them for our needs with a bit of XAML manipulation.

One of these controls is RadDiagnostics. RadDiagnostics catches all unhandled exceptions from an application. And believe me, there will be a ton of them, even if you handle many of them already.

I didn't believe that,either. But then I ran the beta of my TweeCoMinder application for Windows Phone. I tested the application a lot before publishing my beta, including several scenarios like no network connection available, low battery, and so on. At this time, I stumbled over the RadDiagnostics Control in the documentation.

I immediately saw the advantages of using this control:

  • advanced error logging, including a great bunch of information like OS Version, device, network type, and more
  • the application won't crash even on unhandled exceptions
  • the user feels more integrated in the development process
  • users tend to use the application in other ways than we developers think and we can't even get close to catching all those usage scenarios while testing alone
  • there are many users that are really searching for bugs, which is both a good and a bad thing

Let me hook into the last point a bit deeper, since we are able to get the most from it. If users find bugs then they will either get annoyed and stop using our apps or they will report them. Let us make them talk about the problems to us, the developer! Like I mentioned above, the RadDiagnostics control makes this very easy for the user.

A MessageBox shows up where the user is asked to send us the report via email. This has two additional advantages: First, we are able to collect many kinds of errors. An even bigger advantage: We are able to respond directly to the user since we have their mail address. I learned a lot during the first beta versions of TweeCoMinder, be it how users use my application as well as from the coding part, and I was able to continuously improve my application.

Some of you might argue that you don't want the user to see your code. Really, that is stupid. An average user does not even know what all those lines of the exception mean. Only developers are able to understand what is going on. Where is the problem? That they see you have an exception at point x? Chances are very high, that they had the same exception at another point and you need them to iron it out.

Personally, I don't have a problem with the fact that the exception is readable for some beta tester/users. In my experience, users love to give feedback if you make it very easy for them. RadDiagnostics is a very easy way since it needs only three taps (ok => choose mail account => send button).

Since this is a development article, here is how easy it is to integrate it into your application:

  • Declare the RadDiagnostics in public partial class App : Application

    public RadDiagnostics diagnostics;

  • Initiate Telerik ApplicationUsageHelper in private void Application_Launching(object sender, LaunchingEventArgs e)


  • call RadDiagnostic in the App() constructor:

    diagnostics =new RadDiagnostics();{

    diagnostics.EmailTo ="";

    diagnostics.EmailSubject = "Here is your email subject";

    diagnostics.HandleUnhandledException = true;


That's all you need to get it working. A few lines of code that will provide you so much input to improve your application, that will result in this message:


Once again, if you use RadControls for Windows Phone, then use RadDiagnostics to let users help you find bugs. You will not get better and more helpful feedback without it!

You can find the complete documentation of RadDiagnostics here:

Another great article that helps you to deeply understand how RadDiagnostics works is: Kunal Chowdhury's blog.

Similar Articles