Archive for the ‘c#’ Category

C# tips, tricks and things you should know

1 Star2 Stars3 Stars4 Stars5 Stars (3 votes, average: 5 out of 5)
Loading ... Loading ...
Wednesday, November 14th, 2007

.net components During my previous holidays (i have to admit 1.5 months surfing in portugal) I had some literature with me which also included the book Programming .net components released with O’Reilly. It talks about the aspects of components in general and provides good examples how to achieve those in .net. Although these pages are a very good read (rather for experienced devs) for ppl interested in component development, I found it more interesting because of its general C# content. There are concepts & approaches, small tips & tricks and intersting things about C# which can be used not only in component based architectures and are therefore good to know anyway.

As I always make notes while reading “geek” books I thought: “so why not summarize them all up in a nice list and blog’em”. Here we go… (more…)

Singelton application with C#

1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...
Wednesday, November 14th, 2007

A singelton application is an application which only allows running one instance of itself per machine. e.g. Microsoft Outlook is a singelton application. Everytime the user starts the application it will check if an instance is already running. If its not running it will launch it otherwise it will focus to the current one. Here is the source of how to create a singelton application with C# and .net … (more…)

TimeRange object for C#

1 Star2 Stars3 Stars4 Stars5 Stars (4 votes, average: 2.5 out of 5)
Loading ... Loading ...
Friday, August 24th, 2007

In one of my recent .net projects (C#) I had the need to implement an object which represents a time range which is defined by a start time and an end time. In addition it should detect collision with other time ranges and check if given TimeSpans are within the time range itself. Last but not least it should support parsing time ranges from strings and format the range in a nice way. For this I’ve written a small class which could be useful for some of you out there. (more…)