First, if you select, at design-time, all the TextBoxes you wish to assign the same EventHandler to for a specific event, and then open the Property Inspector (F4), you can select an EventHandler you have defined, and it will be wired-up to (added to the invocation list) all the selected TextBoxes. Or, as you have seen, in the other solutions here, you can add the EventHandler in code.
Here's a code example of a KeyPress EventHandler for TextBox, for constraining text input from the keyboard I've used in the past; it will ignore keyboard combinations like Control-V (paste):
private const char chrDelete = (char) Keys.Delete;
private const char chrBackSpace = (char) Keys.Back;
private const char chrEnterReturn = (char)Keys.Enter;
private void DigitsOnlyTextBox_KeyPress(object sender, KeyPressEventArgs e)
{
char currentKey = e.KeyChar;
e.Handled = ! (Char.IsDigit(currentKey) || currentKey == chrDelete || currentKey == chrBackSpace || currentKey == chrEnterReturn);
if (e.Handled) return;
if (currentKey == chrEnterReturn)
{
}
}
To prevent the right-click Context Menu from appearing set the 'ShortcutsEnabled property of the TextBox to 'false: that's the "cheap" way to block the user pasting whatever into the TextBox.
To allow pasting, but intercept the paste event and validate it ... make sure it's all digits ... is complicated in WinForms, but can be done.