I'm developing a system that has some functions (eg F12 -> Close the system). In the system has the form of parameters, and in this form I would like the client to choose which shortcut for each function. detail: each function is a method in source code, so I just need to reference a shortcut to a method at runtime.
if(e.keycode == Keys.F12)
{
FecharSistema();
}
This code and how the system works today, but now has a configurations form where it would be possible to change the shortcut from F12 to F10. In short, let the customer choose which function they will have on each key. Currently F1 - Opens the box, F2 - starts a sale, F12 - Closes the system. But each client wants the shortcut on different buttons. A form has been developed where it is possible for the user to choose which key will perform each function.
How do I change the code for the shortcut to be customizable?