Intercepting commands

 

You can intercept a command when the user chooses it from a menu or from a button. Then the integration can perform some intermediate task before allowing the action to occur. You must intercept external commands.

To customize menu actions:

1. Using RegisterNotify, register the NotifyIM -- MenuIntercept notification to receive an advise when an Imagenation user chooses a command targeted for interception.

2. Use the Imagenation.DDE.InterceptMenuAction(commandID, 1, lhWnd) method to intercept a command and perform the associated action.

Note that you can use the ApproveMenuAction(docwinID, commandID) transaction to allow a command that has been intercepted to proceed as though it has not.

See also