Install A .Net Service Via Command Line

I’ve been working with .Net services for the last few years or so and it is often convenient for debugging to be able to install your debug version. Since it is a major pain to build an installer every time we want to test, we used the command line utility InstallUtil.exe that comes with the .Net Framework to install and uninstall our services in batch files.

If you’ve installed .Net in the default location InstallUtil.exe lives in C:\Windows\Microsoft.Net\Framework\v2.0.50727\InstallUtil.exe
in the respective framework version directory.

Below is an example batch file.

C:\Windows\Microsoft.Net\Framework\v2.0.50727\InstallUtil.exe [your-service.exe]

and to uninstall, use the /u flag

C:\Windows\Microsoft.Net\Framework\v2.0.50727\InstallUtil.exe /u [your-service.exe]

Using these batch files we just create short cuts to them and can double click the short cut to install or uninstall. Of course you can install/uninstall more than one service in the batch file.

Be sure to also check out the other flags available for InstallUtil.

Fantastic .Net Design Pattern Examples

Design patterns are recurring solutions to software design problems you find again and again in real-world application development. Patterns are about design and interaction of objects, as well as providing a communication platform concerning elegant, reusable solutions to commonly encountered programming challenges.

The Gang of Four (GoF) patterns are generally considered the foundation for all other patterns, and the website contains an awesome set of .Net examples for each of the patterns.

Extending Explorer with Band Objects using .NET and Windows Forms

One of the great things about Firefox, is how easy it is to extend. Internet Explorer and Windows Explorer, not so much.  If you’re a ATL or COM guru then you might not find it so hard, but for those of us from a Managed Code background; its like splitting wood in your eyes.

A while ago I found a great article on CodeProject by Pavel Zolnikov, which walks you through the implementation of an Explorer bar with the help of BandObject base class. Describes implementation details of the BandObject class.

This was excellent, but it really didn’t work using the .Net 2.0 framework – that is until I found this little gem Band Objects – .NET 2.0 Redux.

Automatic Update – Yeah!

Cross-posted from the Particls blog.

I got the auto update library and executable working tonight for the (currently somewhat unstable) “experimental” build of Touchstone. It’s well overdue because our little application is getting quite complex now and laying in new features can be a tricky process. Now we have a mechanism to automatically and non-invasively update users with new versions – making adoption and user updates quick, seamless and easy.

Now perhaps Chris won’t kick my ass so hard when a Private Alpha release starts throwing those ugly “object not set to reference of an object” exceptions.

Now all I need to write is a program which automatically updates the blog for me, and I’ll be right!

I just did something very stupid but Chris still loves me

Cross-posted from the Particls blog.

I just opened a .vb file from another project, and upon closing the window (and subsequently not saving) I realised all too late, that Visual Studio had in fact oped the file inside the Touchstone project. You can probably guess the outcome. So off I go again, recoding the complete structure of the BagItAndTagItParser class – be assured that I wont be opening any “stray” .vb files for the rest of the day! Chris is ok with this though, because we just implimented the first ticker system and its actually reasonably functional!

It’s interesting, starting this project has opened my eyes to a whole subculture of RSS, which I was previously unaware of. I think that reading the excellent intellect of Nick (from FeedDemon) and others regarding some sort of solution to the growing ADD (Attention Deficit Disorder) is inspired.
With the rapid expansion of content sources, the more ways we can think of to manage this content without hindering productivity (I am a pragmatist after all) is where we need to redouble our efforts. This is the philosophy behind Touchstone – and I’m coding as fast as I can. Aside from the heavy setback today, I should have the Bag it and Tag It Parser complete before the coding marathon tonight. If you feel inspired enough to chat with us through comments on this blog, please do – we like to feel popular.