Just a sidenote, as you mention Textbox and not Editbox, but due to TAB being a valuable text formatting, the editbox behaviour can be changed via .AllowTabs property.
I also think we had a lengthy thread here about the idea of changing control behaviour via Keypress code. Tamar is right on that, I would not recommend to have too much in there, as it will hardly be maintainable even for yourself one year later.
For example we solved the case to prevent BACKSPACE deleting more than the current textbox in thread184-1654550
Searching for Keypress here in the tek-tips search might find something for whatever your reason to allow some and not other keys.
Bye, Olaf.