C# Null-Coalescing Operator (??)

C# has an operator called Null-Coalescing Operator(??), this operator takes two operands. If left hand side operand is not null then it returns left hand side operand else it returns right hand side operands. It is very effective to assign default value to a variable.

This variable can be used with reference type as well as nullable value types. A sample code for the use of this operator is written below:

ERROR: Couldn't Find BOOTMGR while booting BackTrack via Bootable pendrive

I was trying to boot my machine with Backtrack via bootable pendrive, but unfortunately I got an error by saying

Couldn't Find BOOTMGR
boot:

No need to worry, It has just not found the boot loader. so we will have load that by the command. Just write the following command and it will be start loading

boot: /casper/vmlinuz boot=casper initrd=/casper/initrd.gz text splash vga=791    

now your machine will be start booting with backtrack via your pen drive.

ENJOY!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

How to declare Hashtable or ArrayList in XAML.

To declare Hashtable or ArrayList in xaml, we need to include the System.Collection namespaces in XAML by using the below key
        xmlns:col='clr-namespace:System.Collections;assembly=mscorlib'
After declaring the namespace we can use all the class of System.Collection namespace with col: prefix

Code to Declare the HashTable in XAML:

<col:Hashtable x:Key='hash'>
       <col:DictionaryEntry x:Key='hashEntry1' Key='1' Value='a'></col:DictionaryEntry>
       <col:DictionaryEntry x:Key='hashEntry2' Key='2' Value='b'></col:DictionaryEntry>
       <col:DictionaryEntry x:Key='hashEntry3' Key='3' Value='c'></col:DictionaryEntry>
       <col:DictionaryEntry x:Key='hashEntry4' Key='4' Value='d'></col:DictionaryEntry>
</col:Hashtable>

Code to Declare the ArrayList in XAML: