I have a subform where I am tracking plan vs actual dates linked to the main form by a unique number. On selecting a date using a MS Date and Time Picker on the subform, the user should be able to populate the plan or actual fields onClick. Originally the subform was a popup and worked using the code below. Now I'm receiving a compile error with usage. Do I need to change the way I'm referencing due to using a subform?
Private Sub Actual_Click()
If Me.ActiveControl.Value = Me.txtDateChoice.Value Then
Me.ActiveControl.Value = ""
Else
Me.ActiveControl.Value = Me.txtDateChoice.Value
End If
End Sub
Teri
Good decisions come from Wisdom...
Wisdom comes from experience...
Experience comes from bad decisions
Private Sub Actual_Click()
If Me.ActiveControl.Value = Me.txtDateChoice.Value Then
Me.ActiveControl.Value = ""
Else
Me.ActiveControl.Value = Me.txtDateChoice.Value
End If
End Sub
Teri
Good decisions come from Wisdom...
Wisdom comes from experience...
Experience comes from bad decisions