soupisgood84
Technical User
I have a text_box in a form that will fill a query criteria but when it's blank I want it to insert the following (see below) but I cant seem to get it to work.
Can anyone tell me what I am doing wrong?
Can anyone tell me what I am doing wrong?
Code:
If Me.txtStartDate = "" Then
Me.txtStartDate = "1/1/" & Year(Now)
End If
If Me.txtEndDate = "" Then
Me.txtEndDate = Now()
End If