Why would you want to prevent paste, but allow typing?
If an App did that to me, then I would probably be quite annoyed.
If you really must, then derive a class from textbox, and override WndProc. You can then filter the WM_PASTE message, and disregard it. That should do it.
public class myTextBox : TextBox
{
private const int WM_PASTE = 0x302;
protected override void WndProc(ref Message m)
{
if (m.Msg != WM_PASTE)
{
base.WndProc(ref m);
}
}
}
I still think it's a bad idea though...