Hi guys,
How to sort hashtable keys in ascending order.
I have 5 keys 1,2,3,4,5 and respective values are 10,7,8,6,9,5.
but when i am displaying records it shows like this.....
foreach (DictionaryEntry entry in srque)
{
MessageBox.Show("Key === " +entry.Key);
MessageBox.Show("Value ===" +entry.Value);
}
the output i am getting like
Key=== 4 and value === 9
Key=== 2 and value === 7
Key=== 5 and value === 5
Key=== 1 and value === 10
Key=== 3 and value === 8
How to get output like
Key=== 1 and value === 10
Key=== 2 and value === 7
Key=== 3 and value === 8
Key=== 4 and value === 9
Key=== 5 and value === 5
when i am adding keys and values in hastable inserting it with sorting i.e ascending order.
Thanks in advance..