Capture the OnKeyDown for the Textbox and then use regular expression.
A good post http://www.codeproject.com/cs/miscctrl/maskedcsedit.asp?target=maskedtextbox
I think this one will abt solve ur problems
> use regular expressions
RPRamesh Praveen Syncfusion Team April 29, 2003 02:09 PM
In case you are not aware, Essential Tools comes with a Masked Edit box.