Skip to main content
Legend
September 30, 2016
Answered

Programmatic equivalent for the Find dialog Change functions

  • September 30, 2016
  • 4 replies
  • 971 views

Hi,

Is there a reasonable programmatic equivalent for the Change buttons in the Find dialog? FDK or ES? I have no urgency to find one, but I was going to use it if available. I'm looking for something simple and direct, no wild button-pushing-automation-routines or anything like that.

I hope this isn't a dumb question. I'm amused that after all these years, it is the first time I've ever thought of a need for it.

Russ

This topic has been closed for replies.
Correct answer Klaus Göbel

Hi Russ,

using "find" you'll receive a textlocation. Now you have to "manually" change the text with oDoc.Delete(TextRange) and then insert your replace-text.

I hope, I understood your question right???

4 replies

Klaus Göbel
Klaus GöbelCorrect answer
Legend
October 12, 2016

Hi Russ,

using "find" you'll receive a textlocation. Now you have to "manually" change the text with oDoc.Delete(TextRange) and then insert your replace-text.

I hope, I understood your question right???

Russ WardAuthor
Legend
October 12, 2016

Hi Klaus,

I think you have given me the answer, which is "no." I was looking for a way to programmatically emulate the "Change" buttons. While you explain the simple case of text replacement, it gets much more complicated when you are using regular expression replacements and other special replacement types. So, I think this is simply not exposed in the API, as a packaged operation. It would be nice if they would open that up.

Russ

Legend
October 12, 2016

Hi Russ,

can you give a quick code example, what you have to code now and how you would like to have it in the future?

Cheers,

*Stefan.