View Single Post
 
Old 03-06-2016, 11:43 PM
macropod's Avatar
macropod macropod is offline Windows 7 64bit Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,467
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Word's VBA 'sentence' definition has no idea what a grammatical sentence is, therefore you can't use:
Selection.MoveRight Unit:=wdSentence, Count:=1
reliably to get the next grammatical sentence. The problem with trying to build a set of exclusions of the kind you envisage is that there is no end to the number of possible exceptions once you start trying to cope with every kind of abbreviation & acronym while at the same time handling the fact it's possible a grammatical sentence might actually end with such an abbreviation or acronym. Plus, sentences don't always end with periods...

And no, the "With Selection.Find" function isn't the only one; neither would it be my first choice.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote