
languages, platforms, Object Oriented observations, C#, OOP Patterns
The Problem Statement
You have just started working on an existing codebase – an n-Tier project – and noticed that the Exception Handling framework wasn’t as well defined as you would expect. Some specific things that bother you include:
Lack of … Continue reading
Of the many things I miss in the Classic Windows View – the Windows Explorer navigation is one of them. In Windows 7, the navigation pane (the leftmost pane), does not have the same folder as the rightmost pane (the … Continue reading
The Problem Statement
Imagine that you have just built a sophisticated application to work against a SQL Server database. You followed a best-practices approach and separated out your presentation, business logic and data access layer. Your application is service oriented – … Continue reading
You know you are a techie at heart if you find yourself getting excited at the introduction of a couple of new interfaces.
.NET 4.0 introduces IObservable (Publisher) and IObserver (Subscriber). These interfaces were long overdue – for a couple of … Continue reading
When I opened the ODBC control panel (on Windows 7) and started enumerating the built-in database drivers, I got a bit of a shock. Not only were the Microsoft Access drivers missing from the list – so were a bunch … Continue reading
When tasked with generating Random numbers, some folks use a static method such as that shown below:
Code Snippet
static Random rn = new Random();
static int ReturnNextRandom(int maxIndex)
{
return rn.Next(maxIndex);
}
One of the reasons is that they want to keep the same, common instance … Continue reading
The Issue : Visual Studio throws the following compile time error on a project that includes UI controls (either WinForms or ASP.NET controls).
The item was specified more than once in the resources parameter. Duplicate items are not supported by … Continue reading
Everyone is familiar with the basic swap – using a temporary variable
static void RegularSwapUsingTempVariable(ref int a, ref int b)
{
int temp = a;
… Continue reading
Symptom
File has already been deleted (from source control and from the filesystem). Yet – the file shows up in the Visual Studio solution (with a yellow warning icon next to it). When one tries to compile, one sees the above … Continue reading
I am still not sure why Adobe (the company) does not offer an online editing tool for editing pdfs. Until they offer something like this, one has to rely on 3rd party vendors who have filled in this gap. My … Continue reading