Wednesday 26 December 2012

Single cast delegate vs. Multi cast delegate

In C# all delegates are multicast delegates. A singlecast delegate is simply a multicast delegate with one handler attached. All delegates inherit from System.MulticastDelegate in mscorlib.

The Underlying Type of an Enum

Enums in C# are generally backed by the underlying type int (actually System.Int32). This is a signed value ranging from -2 billion to positive 2 billion (a little over, actually, 2.147 billion).  However, this underlying type can be overridden e.g. enum Selection : sbyte. Now the enum is a signed 8 bit integer (ranging from -128 to 127). Note, however, that the base type of Selection is System.Enum and not sbyte! Forget what you know about base type specification!

Sunday 2 December 2012

Technology

Technology (especially hardware) can be quite intimidating for those unaccustomed to the products out there. Features seem to be implemented beyond what the end-user wants or needs. It takes time to get familiar with the products out there. There may be many manufacturers. This is more true for appliances e.g. kitchen appliances, home technology etc. much more so than computing, which has become quite commoditised as of late.

Disable Privacy Warnings in Excel when Saving Workbooks

Go to Developer tab, and select the "Macro Security" button (with the "Roadworks" sign), Privacy Options and un-check everything. Hey Presto, you are done!