1/ I think you need to exclude spanner that are not in the selected track
2/ It will work with slurs, but other spanners like voltas are a bit different the end on the tick of next measure I believe.