I'm not sure why I'm having such a hard time with this because I've done it before with a combo box, but when I use the following code with a text box, I get the "Can't assign value to this object." If the user doesn't enter a pend date, I want it to assign the current date + 7 days to the PEND_DT field in my Table. Maybe I'm using the wrong event?
Private Sub Form_Close()
Dim strHoldDate
'Returns current system date plus 7 days
If IsNull(txtPendDate) Then
strHoldDate = DateAdd("d", 7, Date)
Me![PEND_DT] = strHoldDate
End If
End Sub
Thanks!
Liz
Private Sub Form_Close()
Dim strHoldDate
'Returns current system date plus 7 days
If IsNull(txtPendDate) Then
strHoldDate = DateAdd("d", 7, Date)
Me![PEND_DT] = strHoldDate
End If
End Sub
Thanks!
Liz