You should not use non-generic HashTable
to start with. Use generic Dictionary<int, string>
instead:
var d = new Dictionary<int, string>();
d.Add(1 , "ABC");
d.Add(2 , "AgC");
d.Add(3 , "ABC");
d.Add(4 , "AhC");
var posi = from a in d
where a.Value == "ABC"
select a.Key;