Willy's Reflections

| Willy-Peter Schaub | Visual Studio ALM Rangers | In search of IT simplicity, quality and tranquility |

Debugging .NET Applications … a power course (day 2/2)

Debugging .NET Applications … a power course (day 2/2)

  • Comments 1

Day one was covered in Debugging .NET Applications … a power course (day 1/2) … let’s summarise the exciting journey during day 2.

Clipart Illustration of a White Character Standing In Front Of A Chalkboard And Teaching A ClassThe menu was amazing … watch windows, visualizers, DebuggerTypeProxy, remote debugging, exceptions, error handling, WinDBG, PSSCOR2, performance tuning, IL, and lots, lots more. Again all machine less … an amazing course and one which will keep my head spinning for a long time.

Remote debugging was always a mysterious feature to me … but after today, it is going to be one of the invaluable tools in the debugging toolbox. WinDBG was always intimidating, but again, it is a really cool tool and as long as you remember the .help command, you are A OK :)

image … WinDBG in action
… using Visual Studio Debugger and WinDBG gives you the best of both worlds!

Comment of the day

The comment came from day one, but still has me in chuckling “Code as if whoever maintains your code is a violent psychopath who knows where you live”.  It was made while we were chatting about commenting code. make your day and visit http://stackoverflow.com/questions/184618/what-is-the-best-comment-in-source-code-you-have-ever-encountered for a series of code comments which will have you laughing on the bus all the way  from the office to home, such as:

Catch (Exception e) {
//who cares?
}

… or …

//
// Dear maintainer:
//
// Once you are done trying to 'optimize' this routine,
// and have realized what a terrible mistake that was,
// please increment the following counter as a warning
// to the next guy:
//
// total_hours_wasted_here = 16
//

 

.. if the above does not bring a smile to your face, nothing will :)

Tip of the day

“Manually typing PSSCOR2 commands over and over leads to on the job injuries” … additionally my inability to remember names, adds to the pain. The undocumented command .cmdtree, plus the formatted command tree file, delivers a powerful tree menu of all important commands:
image … this feature has just sold WinDBG to me :)

John also referred us to the site http://blogs.msdn.com/tess … a phenomenal site, filled with debugging nuggets! Bookmark this blog today!
image

Conclusion

This course is amazing and I recommend that you visit Wintellect, www.wintellect.com, for details on the “Debugging .NET Applications” courseware … worth every second! My head will be spinning for weeks, months …

Thank you John, for an interesting and exciting two days, and a really worthwhile course!

Leave a Comment
  • Please add 2 and 5 and type the answer here:
  • Post