How can I run a method when someone used a keyboard shortcut like Ctrl+ G?
An application is a Windows forms application, and I only want to capture it when the form is activated.
Key shortcuts are often called "command keys." If you want the first crack of keystrokes (before your child control), it is best to override the ProcessCmdKey method in your form.
Look at your OnKeyPress method on the form or KeyPress event for the form.
Override OnKeyPress like this ...
protected override void OnKeyPress(KeyPressEventArgs e) { ... }
... KeyPressEventArgs, , , Ctrl.
SO , KeyPress... "Ctrl" keydown #
Source: https://habr.com/ru/post/1763178/More articles:Do Adobe Air applications support multi-core processing? - airAdding a previously defined macro to a macro ring in Emacs - emacsGetting a previously focused element - javascriptjQuery: определить, является ли объект jQuery корневым тегом html - javascriptcasting problem from SqlDataReader - c #can i put a scrollable text box in uialertview? - iphoneAn interesting console program for beginners C ++ - c ++JQuery move elements get all previous elements that match the selector - jqueryWhat are the benefits of EF4 or LINQ to SQL? - linq-to-sqlХранить BLOB в Android SQLite с помощью SQLOpenHelper - javaAll Articles