Disabling (or capturing) CTRL+A in SyntaxEditor

SyntaxEditor for WPF Forum

Posted 9 years ago by tal
Version: 13.2.0590


I wish to supply a different implementation for the SelectAll Command and I thought to implement it by capturing the CTRL+A key event (up or down).

I was unsuccessful even after unbinding the SelectAll command using:

foreach (KeyBinding item in editor.InputBindings)
    if ((item.Key == Key.A) && (item.Modifiers == ModifierKeys.Control))

How can i achieve the desired effect?


Comments (2)

Answer - Posted 9 years ago by Actipro Software Support - Cleveland, OH, USA

Hi Tal,

You might also have to remove EditorCommands.SelectAll from the SyntaxEditor.CommandBindings collection too.  That should do the trick since I think that command has a Ctrl+A input gesture on it as well.

Actipro Software Support

Posted 9 years ago by tal

That still didn't fire the events for KeyDown & KeyUp (with the e.Key == Keys.A and the CTRL pressed), I decided to use CustomCommandBinding & CustomInputBinding to override the CTRL+A event and it did the trick.


The latest build of this product (v22.1.4) was released 19 days ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.