private int RowIndexAtExact(int yPosition)
{
int height = 0;
for (int i = 0; i < this.Rows.Count; i++)
{
Row row = this.Rows[i];
if (row.Parent == null || row.Parent.ExpandSubRows)
{
height += row.Height;
if (yPosition < height)
return i;
}
}
// If we've got this far then its the last row
return this.Rows.Count - 1;
}