Replace() with custom evaluator is only finding first match

I’m trying to find all matches of a word with a regex pattern and print them to the console. When using getRange().replace(), its only finding the first match in the file.

I’ve attached my sample code and file below. Any help would be appreciated.

AsposeFindTextWithRegex.zip (14.1 KB)

RegexTest.zip (9.3 KB)

@austinmcnicholas

We have already answered your query here in this post. Please follow that thread for further proceedings.