Is there a way to mask text boxes so that they will only accept dates or times?

If not, how can I use a validation webcontrol to ensure that a date or a time was entered into an associated text box?