Category Archives: coding

scriptcs – Living on the edge in C# without a project on the wings of Roslyn and Nuget

  Disclaimer: I am not the first person to create a tool for C# scripting. There are a long list of projects from too many people to name, and I respect all of them A big part of why I … Continue reading 

Also posted in rosyln | 13 Comments

Monotouch: drawing an image pixel by pixel

I have been exploring Monotouch, a C# development environment for the iPhone/iPad,  for some time now. And I really do like it. The learning curve is somewhat steep, but after getting familiar with the (rather strict, but not bad at … Continue reading 


Catching the iPhone in the .net

Smartphones and all other kinds of mobile devices are everywhere, almost everybody has one. Not just for entertainment but also as a client for all kinds of enterprise software. Making choices when developing desktop software was easy, the main discussion … Continue reading 


CodePaste is the bee’s knees, my new favorite way to share code.

Ever need to share code-snippets with the twittersphere? If so, Codepaste is for you. It’s my favorite new tool for getting code out there in a really low-friction manner. It has really nice syntax coloring support, allows reviewers to comment, … Continue reading 

Also posted in misc | 3 Comments

DDD and repositories. Without nHibernate but with lazy loading

Domain driven design has become a very prominent way to develop software. A central domain model is used by all participants. To the end user it is a representation of the real  world. To the coder the model is a … Continue reading 


WPF = Code + Markup (Custom pushpins for DeepEarth)

Windows Presentation Foundation has been around for a relative short while. Silverlight brings WPF to the browser, with that the amount of writings on WPF is growing fast. At the moment I’m working on a project which uses Deep Earth, … Continue reading 


NET DateTime, SQL dateTime, SQL date, a small Cheatsheet

Recently I blogged a little on my wrestlings with dates in SQL server. Some commenters suggested using a custom type instead of the sql datetime . Stefan pointed to the nHibernate Ticks type as a good way to handle the … Continue reading 


Valid date-time values in sql server. SqlDateTime vs DateTime

You cannot store every date in sql server. The valid range of dates is from 1/1/1753 (1-1-1753) to 12/31/9999 (31-12-9999). The range of the .NET DateTime type is far larger. So before storing a datetime in a sql server database … Continue reading 


What really went wrong ? Check the inner exception

In his recent overview on Exceptions Karl briefly mentioned the inner exception. By passing an exception to the constructor of the new exception, the exception passed in becomes the new exception’s InnerException property. private void workWithFile() { try { // … Continue reading 

| Leave a comment

Wrapping up nHibernate in repositories

In my last post I discussed wrapping up the two core objects of nHibernate, the sessionmanagerfactory and the session, in a helper class. At the end of the story I briefly mentioned how to use helper objects in a repository. … Continue reading