I have the code below it allows me to choose a date from today to 30 days from now but excludes any days past the 28th of the month. Now it works great but if I choose today’s date it gives a null value and the database returns a mismatch data error. if I choose tomorrow or any date pass today it works great. Any help with this?
<%
'0-29 = 30
'1-30 = 30
For x = 0 to 29
NewDate = DateAdd("d", x, Date())
If Day(NewDate) < 29 Then
Response.write "<option value=""" & NewDate & """>" & NewDate & "</option>" & vbCrLf
End If
Next
%>
<%
'0-29 = 30
'1-30 = 30
For x = 0 to 29
NewDate = DateAdd("d", x, Date())
If Day(NewDate) < 29 Then
Response.write "<option value=""" & NewDate & """>" & NewDate & "</option>" & vbCrLf
End If
Next
%>