Private Sub Command4_Click()
On Error GoTo Err_Command4_Click
DoCmd.SetWarnings False
DoCmd.OpenReport ("R_Standard Monitoring Report"), acViewPreview, , "[T_Formatted data]![Period] = Me.Period.Value"
Exit_Command4_Click:
Exit Sub
Err_Command4_Click:
MsgBox Err.Description
Resume Exit_Command4_Click
I have written the above code which is supposed to filter out records on the report. However, when i click on my OK box, it asks me for a vlaue for the field Me. Period.Value.
Any ideas why this may be ?????
The field on the form which contains the data for the filter is called Period.
On Error GoTo Err_Command4_Click
DoCmd.SetWarnings False
DoCmd.OpenReport ("R_Standard Monitoring Report"), acViewPreview, , "[T_Formatted data]![Period] = Me.Period.Value"
Exit_Command4_Click:
Exit Sub
Err_Command4_Click:
MsgBox Err.Description
Resume Exit_Command4_Click
I have written the above code which is supposed to filter out records on the report. However, when i click on my OK box, it asks me for a vlaue for the field Me. Period.Value.
Any ideas why this may be ?????
The field on the form which contains the data for the filter is called Period.