Hi,
Can anyone see what the syntax error in filter criteria in this code is?
I really struggle to get my head round the 's "s and &s and I can't see for looking what is wrong with the code, but I am getting a syntax error message every time it runs.
I have tried moving the ' to immediately after Total Name = but I get the same error.
This is the only bug left in the new database I have made, which is due for presentation to my boss in 1.5 working days.
Argggggh!
Can someone help me?
Thanks in anticipation, Mike.
Can anyone see what the syntax error in filter criteria in this code is?
Code:
If CurrentProject.AllForms("TrainingRecs").IsLoaded Then
Me.Filter = "Total Name =" & "'" & Forms![TrainingRecs]![TotalName] & "'"
ElseIf CurrentProject.AllForms("ReportTrainee").IsLoaded Then
Me.Filter = "Total Name =" & "'" & Forms![ReportTrainee]![TotalName] & "'"
Else: End If
I really struggle to get my head round the 's "s and &s and I can't see for looking what is wrong with the code, but I am getting a syntax error message every time it runs.
I have tried moving the ' to immediately after Total Name = but I get the same error.
This is the only bug left in the new database I have made, which is due for presentation to my boss in 1.5 working days.
Argggggh!
Can someone help me?
Thanks in anticipation, Mike.