Discussion:
Is there any way to reliably override change tracking actions in Word?
(too old to reply)
b***@gmail.com
2013-03-14 04:23:49 UTC
Permalink
Suppose change tracking is on, user deleted some text, then right-clicks on that deleted interval and chooses "Reject Deletion". Further, suppose I want my custom VBA code to execute in this case, instead of whatever standard action. How do I accomplish this (and can it be done at all?)

Ditto for related variations, such as "Reject Insertion", "Reject Move", etc...

Of course, the context menu is just one thing to worry about here; there's also a possibility of the user choosing "Reject Change" or "Accept Change" from the ribbon.

So far I've overridden all of the following built-in commands (gleaned with the aid of the Macros dialog):

RejectAllChangesInDoc
RejectAllChangesShown
RejectChangesAndAdvance
RejectChangesOrAdvance
RejectChangesSelected

None of them appears to be invoked when users reject individual changes via the kinds of interaction described above.

Is there yet another and/or some undocumented built-in command for single-change rejection, that I'm missing?

(In reality, I'd also like to get my custom code called when users accept changes, but I'm assuming the solution -- if any -- would be analogous to the reject case...)

If it helps, or makes any difference, I'm currently working with Word 2007...
b***@gmail.com
2013-03-16 00:31:05 UTC
Permalink
Got my answer on MSDN VBA forums: there's an addition set of commands related to change tracking accept/reject, among them "ToolsRevisionMarksReject". The latter, for instance, is the one invoked when user rejects individual changes.

Hope this helps anyone else who might face a similar problem.

Loading...