Added getIndex

I was in a situation when scrolling was off and to simplify the search of last known index ive added this function.