Revert "Revert "selected range works""

This reverts commit dc04662b9c2d481fdb53899a907ae9ab0815246b.