RegEx to Match Sentence -- Works in but not KM

Why doesn't this work in KM? Match Sentence
([A-Z].+?(?=(?:\. {1,2}[A-Z])|[\.?!]$)[\.?!])

KM match stops at first period:
Here is a sentence with abbrev. Results


MACRO:   RegEx to Match Sentence

~~~ VER: 1.0    2019-02-16 ~~~


RegEx to Match Sentence.kmmacros (5.4 KB)
Note: This Macro was uploaded in a DISABLED state. You must enable before it can be triggered.


Your regex depends on case but you've set the action to ignore case.

1 Like

Bingo! :+1:
I can't believe I made such a rookie mistake. :blush:
The RegEx and macro now work perfectly.

I have made some minor updates to the RegEx: Extract Sentence from Paragraph

Thanks again @mrpasini.

Here's my finished Macro for Pages based on this:
MACRO: Pages -- Select Sentence [Example]

Happy I was able to help!