Categories
Programming

WPF BackgroundWorker and the Mysterious 0x80131623 Error

If you use Windows Presentation Foundation (WPF), you are very likely to come across the awesome BackgroundWorker and its best friend the Dispatcher. The BackgroundWorker lets you chuck a long-running process onto another thread, allowing the UI to remain responsive. When the BackgroundWorker needs to pop something on the UI, you ask the Dispatcher to […]

Categories
Programming

Fixing .htaccess Rewrite Problems with RewriteBase

I recently encountered an issue on an otherwise perfectly functioning .htaccess file, which contained mod_rewrite rules. The rules had been working for several years (since 2008 to be precise) but some patch or change on the web server suddenly caused all pages except for the home page to be unavailable. The error suggested that the […]

Categories
Pie Charts

Continued Pie Chart Hatred

You might have heard me mention that pie charts are bad and should never be used and you may have read my article explaining why you should never use pie charts. Well, every now and then a really good example pops up to illustrate exactly why you shouldn’t waste time on those little circular devils, […]

Categories
Programming

Improving Your Code with NDepend and CQL

I have been talking a fair bit recently about code quality tools such as Resharper and NDepend. In this article, I will explain how to use one of the features of NDepend to improve your code quality. On of my favourite features of NDepend is the suite of “code query language” tests, which run against […]

Categories
Programming

Adding Multiple Lines to Descriptions in ICalendar Files

ICalendar files (or iCal files) are used to share event information. You just download the file and open it up using your preferred calendar tool and it adds the event to your calendar. This is great as it means you don’t need to copy and paste the event information into a new meeting. One issue […]

Categories
Programming

Optimising Your jQuery

jQuery is taking the JavaScript world by storm, but because it makes life so easy, it also makes it easy to forget about the amount of work you are asking the browser to do. This is especially important if you are performing an action against multiple elements, in a loop or as part of an […]

Categories
Programming

NDepend Contextual Help

I’ve talked a couple of times about NDepend recently, in the article NDepend For Beginners. NDpend is jammed full of code analysis tools, but sometimes you need a bit of a hint to tell you what is going on in the various matrix displays and graphs – well now NDepend is getting some improvements to […]

Categories
Programming

NDepend for Beginners

NDepend is a code-quality tool that integrates with Visual Studio (2008 and 2010… and probably older versions too if you happen work in a museum). Within about 10 minutes of installing NDepend, I had already created a really handy component diagram that pointed out that one of my name-spaces was wrong. I haven’t even properly […]

Categories
Programming

Mocking NHJump In Your Unit Tests

NHJump is an excellent way to jump start your NHibernate implementation, giving you instant repositories and query definitions from the word go. Here is a quick bit of information on how you can go about stubbing and mocking the NHJump repository for the purposes of Unit Testing. Please note… this is an initial draft and […]

Categories
Programming

Beginners Guide To JavaScript Form Validation

Update! You may want to check out some native HTML validation attributes that are way better than JavaScript validation! JavaScript form validation is a great way to hint to your users what they should be typing into your web page. It isn’t a replacement for validation on the server, as it can be bypasses incredibly […]