G
Guest
Hi,
This code worked for a while, then stopped. I'm trying to be sure the
client completes a "Limitation" field called cboLimits, before printing, and
I have the following code:
If Me.Dirty Then 'Save any edits.
Me.Dirty = False
End If
If Me.NewRecord Then 'Check there is a record to print
Msgbox "Select a record to print"
Else
strWhere = "[ID] = " & Me.[ID]
If cboLimits = "" Then
Msgbox "Enter limitations, if any."
Me.cboLimits.SetFocus
Exit Sub
Else
DoCmd.OpenReport strReport, acViewPreview, , strWhere
End If
End If
End Sub
It doesn't seem to be evaluating the cboLimits field, and just prints an
empty space in the field on the report.
Am I missing something?
Thank you,
Karl
This code worked for a while, then stopped. I'm trying to be sure the
client completes a "Limitation" field called cboLimits, before printing, and
I have the following code:
If Me.Dirty Then 'Save any edits.
Me.Dirty = False
End If
If Me.NewRecord Then 'Check there is a record to print
Msgbox "Select a record to print"
Else
strWhere = "[ID] = " & Me.[ID]
If cboLimits = "" Then
Msgbox "Enter limitations, if any."
Me.cboLimits.SetFocus
Exit Sub
Else
DoCmd.OpenReport strReport, acViewPreview, , strWhere
End If
End If
End Sub
It doesn't seem to be evaluating the cboLimits field, and just prints an
empty space in the field on the report.
Am I missing something?
Thank you,
Karl