/ Published in: Regular Expression

This only constraint here for smalldatetime is the year which allows 1900-2079. This does allow normal months and days so you could go outside the smalldatetime since that allows only 1/1/1900-6/6/2079.
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
^(([1-9])|(0[1-9])|(1[0-2]))\/(([0-9])|([0-2][0-9])|(3[0-1]))\/(([1][9][0-9][0-9])|([2][0][0-7][0-9]))$
Comments
