Is it possible to sort a HashTable?
Hashtables work by mapping keys to values. Implicit in this mapping is the concept that the keys aren't sorted or stored in any particular order.
However, you could take a look at SortedDictionary<K,V>
.
Another option is to construct the hash table as you're already doing, and then simply construct a sorted set from the keys. You can iterate through that sorted key set, fetching the corresponding value from the hash table as needed.