I am having some trouble iterating through a `IList<Hashtable>`. I am trying to iterate it by index i.e.:

I have an `IList<Hashtable>` with 3 different `Hashtable`s in it. I want to `foreach` each one by `IList`'s index. In example:

I want first to `foreach` all `KeyValuePair`s in `Hashtable` in `IList` index=0. When finished do some stuff and then `foreach` all `KeyValuePair`s in `Hashtable` in `IList` index=1 and so on until all `Hashtable`s are iterated through. Currently the code is as follows:

variable `data` is an `IList<Hashtable>` with 3 `Hashtable`s in it.

```cs
foreach (Hashtable rowData in data[index])
{
    some code here...
}

```

I get the following error:

> 
> Unable to cast object of type 'System.Collections.DictionaryEntry' to type 'System.Collections.Hashtable'.
> 
> 
>