Page 1 of 1

Move Previous Sentence Macro Problem

Posted: 2010-06-11 18:44:59
by goldste4
Hello All,

I'm using the Move Previous Sentence and Move Next Sentence Macros from the macro repository (just installed them the other day, so I imagine that they are current).

The Move Next Sentence Macro works exactly as advertised, however the Move Previous Sentence macro has very odd behaviour: whenever there is a sentence with a comma in it the insertion point moves to the comma and then gets "stuck" there, so that the insertion point won't move to the previous sentence no matter how many times the Move Previous Sentence is run.

I see that there was some discussion of what I assume was an older version of the macro at: http://www.nisus.com/forum/viewtopic.ph ... nce#p17009, but from that discussion it seems like earlier issues had been solved.

Any suggestions?

Thanks,
Josh

Re: Move Previous Sentence Macro Problem

Posted: 2010-06-14 11:30:18
by martin
Hi Josh,

It looks like you found a bug in the macro. I've updated the macro repository to fix the "Move Previous Sentence" macro. If you don't want to download the full archive of all sentence macros again, here's the fixed code for just the one macro:

Code: Select all

Select Sentence
Select Start
Find Previous '\p{Punct}+\s+', 'E-W'
Select Start
Thanks for letting us know.

Re: Move Previous Sentence Macro Problem

Posted: 2010-06-14 17:06:43
by goldste4
Hi Martin, thanks, that works great! Josh