Check out Mahesh's article on the subject:

http://www.c-sharpcorner.com/uploadfile/mahesh/maskedtextbox-in-C-Sharp/