If you happen to be experienced in development using Visual Studio, but a bit new to working in XCode for iOS development (like me), you are probably used to your application breaking on exceptions during debugging.  But by default, your iOS application may not act as you expect when it comes to debugging crash exceptions.  You may instead see something like this:


testbreak.xcodeproj — main.m

With an error message that says: 

*** Terminating app due to uncaught exception


What?  Why was my exception uncaught while I am debugging?  I, for one, would rather be taken to the point at which the exception ...

Last week I found myself debugging an issue with Apple Push Notifications service (APNs) on one of our development servers, and learning a bit about APNs certificates and Windows Server 2008 R2 with IIS 7.5 in the process.

 

My first task was to try to isolate why the push notifications weren't received by our iOS devices, so I started on my local development machine.  I installed the certificates into my personal certificate store, stepped through the notification code, and sure enough I heard my iPad chirping telling me the notifications were being received.  It turned out that the certificates ...

In case you haven't heard.. JAVASCRIPT IS MAKING A COME BACK!! And it is not the same JavaScript you fiddled around with in the pre-AJAX era. It has become reborn with the help of HTML5, mobile, and even Windows 8 (see Create your first Metro style app using JavaScript). Understanding JavaScript is becoming essential and can no longer be dismissed as a "weakly-typed, toy language with no compilation checks," but instead as a versatile, dynamic, cross-platform language.

Before jumping into code and learning JavaScript, I want to give some background of its purpose. It is important to know ...

It is quite easy to enable Out-of-Browser (OOB) mode when building a Silverlight application.  Open up the project properties on the Silverlight project and check the box to "Enable running application out of the browser."

The more difficult task is troubleshooting problems when the application works in browser, but not out of browser.  First, to debug OOB applications in Visual Studio, you need to open the Silverlight project properties and in the "Debug" tab, set the start action to "Out-of-browser application" and select the appropriate project from the dropdown list.  Next, set your Silverlight project as the startup project.  Now ...

Even though I’ve been doing ASP.NET for 8 years, I never realized until today that when you put a breakpoint in Application_Start in Global.asax, it may never be hit.  The reason, I discovered, is that the debugger doesn’t have time to attach to the web application before Application_Start finishes.  To get around this, you can force your application to restart after the debugger has had a chance to attach by simply editing and saving a change the web.config.  This causes the application to restart and your breakpoints in Application_Start will now be hit.

Firefox closely follows Javascript and CSS standards better than any other browser. For this reason, I code against Firefox as my primary browser, then apply necessary changes to other browsers. This is in spite of Internet Explorer being the most popular browser (this may change one day) and my love for Chrome.

Another compelling reason to use Firefox for your web development is because of the unmatched add-ons. I am not just talking about any add-ons, but add-ons that makes you a more productive developer. Those are the kinds of add-ons I would like to cover in this ...

If you are using conditional directives in your C# code, you know that you can't set a breakpoint on any code within the directives using Visual Studio. Thankfully, you can add a breakpoint programmatically:

#if  MYSYMBOL
#if DEBUG
System.Diagnostics.Debugger.Break();
#endif
DoSomethingForMySymbol();
#else
#if DEBUG
System.Diagnostics.Debugger.Break();
#endif
DoSomethingForEverythingElse();
#endif

System.Diagnostics.Debugger.Break() can only be called in Debug mode, so make sure you wrap it in a #if DEBUG check first. Good luck!