I don't know if this helps, but you can somewhat control this by the input box itself.
You can right click the input box, properties->constraints->Click custom
then define it as something like
len($)=8 and mid($,5,2) <= '12' and mid($,7,2) <= 31
Then you can also check error message below and type in something like:
Please enter date in the format 'YYYYMMDD'
Now whenever the user enters in a date that does not follow your parameters this error message will pop up until they meet the correct requirements.
I will try making it in a macro next but figured this might fix your problem without the use of a macro.
Hope this helps!