Working with resource files (.resx) in Visual Studio 2002/2003/2005 is very easy and straightforward. A .resx file is a fairly simple XML file that can be used for a lot of things. Where I have used it the most is for localization of ASP.NET websites and Windows Forms applications. All though it can contain images and other file types, I have only used for storing strings.

At work, we are working with a localized ASP.NET application that has to be translated into several different languages. So we use .resx files for storing these languages. Us, the developers, do not do the actual translating our selves. Nor do we decide what to be written in the first place. That’s for the copywriters to decide and control.

The problem is that they do not have the means to control the text without going through one of the developers that can easily open the .resx file in Visual Studio and make the changes. The copywriters haven’t got Visual Studio installed and cannot open the .resx in Notepad to make the changes in the raw XML. It’s just too complicated. It would also be a bad idea to let them modify the XML document manually, because if they make a syntax error, the whole .resx file will be invalided and the website would throw a lot of exceptions.

So, I searched the web for an application designed for editing resource files. I wanted to find a simple and intuitive application, but I couldn't. Not even Scott Hanselman's ultimate list of tools offered me one.

That’s when I saw the light and decided to write my own little resource editor application. It is written entirely in C# 2.0 and is deployed as a ClickOnce application. It is a very simple app, which only does what it is supposed to do – edit resource files. No more, no less. The only added feature is a security lock down for the name column. This will prevent the copywriters from editing the name and deleting and adding rows. This can be turned on and off by checking the check box in the bottom left corner.

Resource editor

Give it to your copywriters and let them edit the text by them selves.

Download the Resource Editor application
Download the C# project

Enjoy.

I have unit tested my code for years now, but have never got around to using a unit testing framework like NUnit. I’ve been dancing around it for some time now, but haven’t had the time to get to know it or maybe I just forgot about it. I manually write my tests and it works fine, but it does not provide the level of consistency that NUnit provides.

So I decided to read the book "Test-Driven Development in Microsoft .NET", to get me started, or at least inspired. The book is written by James Newkirk and Alexei Vorontsov. James works with Patterns & Practices at Microsoft and has also been involved in developing NUnit. So who better to write a book about test driven development (TDD) than him??

The book does a very good job describing the philosophy behind TDD and the idea of writing scenario based unit tests. I have never thought of doing that, even though it is very simple. That covers about 3 of the chapters, and they were very informative and interesting.

The funny thing is that the book is about TDD, it says so on the cover. Nevertheless, the authors spend approximately 9 chapters writing about something else. If I wanted to know more about creating web services, I would buy a book about it. The same goes for refactoring and data access code.

The book is written for beginners to .NET development, even though the authors claim it is for experienced programmers. If you are an experienced programmer, expect to be bored for three quarters of the book.

My guess is that the authors had written their 3 interesting chapters when the publisher, Microsoft Press, wanted at least 12. So the authors had to write a lot of words to get to the 12 chapters - and so they did. The book suffers from the same disease as "Naked Conversations" does - example overflow. Read my review of Naked Conversations here.

However, the three good chapters are actually worth the while, so I will recommend the book, but instruct people to skip 9 chapters.