Out of range Exception in helper resolved