Why does retrieving resources have to be so difficult? Oops, it’s not…

Loading embedded resources at runtime has always mystified me.  Should I use the ComponentResourceManager class?  Should I try to find the ResourceStream in the assembly?  And what’s the correct name to use to identify it?  Is it simply the file name? Or is it the name of the default namespace plus the filename?  Or do…

0

C# Extension Methods: Syntactic Sugar or Useful Tool?

Last week a colleague introduced me to extension methods (C#, VB) in .Net. If you’re not familiar with extension methods, they were added in Visual Studio 2008 to provide a means for adding functionality to existing types without creating a new derived type. Extension methods are called as if they were instance methods of the…

0

Hiding a non-virtual property for a derived control at design-time

I’ve recently been developing a custom control (BarControl) that derived from an existing control (FooControl). There were two requirements related to the derived control’s border style: The BorderStyle property should not be modified at runtime The BorderStyle property should not be displayed in the Properties pane at design-time Since the base control exposed a BorderStyle…

0

Back in Business

After a hiatus of 3+ years, I’ve decided to reopen blue collar.  The focus will no longer be the .Net Compact Framework, but will still be aimed at providing information and solutions that will save time and effort for developers delivering solid code on a daily basis.  If you find these articles useful, please let…

1