Quantcast
Channel: Word for Developers forum
Viewing all articles
Browse latest Browse all 4350

Calling EditReplace dialog from a macro

$
0
0

In Word 2003, I used to call the EditReplace dialog through a macro, wherein some operations were initially made on the Find and Replace fields, and then the dialog was called through Dialogs(wdDialogEditReplace).Show. The dialog, apart of the preprepared Find and Replace fields, presented also, as it is usual, a list of previous replacement texts as a dropdown list of the Replace field. In addition, the dialog was modal, which allowed to make some final operations after the dialog box was dismissed.

Now, in Word 2013, everything works almost the same, with a very inconvenient difference – both Find and Replace fields have empty history; and thus I cannot use any previous replacement texts. Additionally, no formating is indicated, even if some is active and applies on replacing.

When I replace ‘Dialogs(wdDialogEditReplace).Show’ with ‘SendKeys "^H", True’, the resultant dialog box has all the previous replacement texts available, and formatting, if any, is clearly indicated as it should be, but unfortunately the dialog box is now a modeless window, and no final operations are available after dismissing it.

Is there any way to restore the Word 2003-like mode of operation?


Viewing all articles
Browse latest Browse all 4350

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>