The subject line is the error message that I get when I try to set the value of a yes/no field through code and I cannot figure out what's causing the issue.
Here's my code (the part in red is where my code stops working):
Any help that you guys can provide would be appreciated.
Travis
Here's my code (the part in red is where my code stops working):
Code:
Private Sub Form_Open(Cancel As Integer)
On Error GoTo Err_Form_Open
Dim strUserID As String
Dim DueDate As Date
Dim DateCompleted As Date
DoCmd.SetWarnings False
DoCmd.RunMacro "mcrMaximize"
strUserID = GetUserName_TSB
DueDate = Form_sfrmGDSQADates.DueDate
DateCompleted = Form_sfrmGDSQADates.DateCompletedGDS
If DueDate < DateCompleted Then
[COLOR=red]Form_frmGDSQA.TimeN1 = True[/color red]
Form_frmGDSQA.TimeY1 = False
Else
Form_frmGDSQA.TimeN1 = False
Form_frmGDSQA.TimeY1 = True
End If
DoCmd.SetWarnings True
Exit_Form_Open:
Exit Sub
Err_Form_Open:
DoCmd.SetWarnings True
MsgBox Err.Description
Resume Exit_Form_Open
End Sub
Any help that you guys can provide would be appreciated.
Travis