Fill text box based on combo box selection

  • Thread starter Thread starter Scott
  • Start date Start date
S

Scott

Hello-

I have a form called frmInquiries. There is a combo box called
cboInqStatus and a text box called txtResolveDate. The two values in
the combo box are "Active" and "Completed". >What I want to do is to
have txtResolveDate filled with the current date once the user changes
the combo box from "Active" to "Completed". Any ideas on this? Thanks
in advance for the help.
 
I think I figured this out with the following code in the After Update
event of the combo box:

Private Sub InquiryStatus_AfterUpdate()
If InquiryStatus = "Completed" Then
Me.ResolveDate = Date
Else
Me.ResolveDate = Null
End If
End Sub
 
Back
Top