Scott said:
Rick,
Case No is the text data. It seems the space in the Query or Table
name enclosed with square brackets works fine.
Did you mean I replace the criteria with "[Case No] = '0001'")? I
tried it and it worked correctly with parameter query. What is wrong
with this setup?
I'm confused by this response. Did you get it working or not?
Any time you are struggling to get a complex expression working it is a
good idea to break it down into its simpler components and see what
happens. For example if I Have the expression...
DCount("FieldName", "TableName", "SomeField = '" Some form reference" &
"'")
...that isn't working I can break it down by first eliminating the third
argument altogether...
DCount("FieldName", "TableName")
If that works I know the problem is with the third argument. In that case
I try a simpler expression there to see if that gives me the results I
expect...
DCount("FieldName", "TableName", "SomeField = 'AValue'")
If that works then I know that it is the form reference causing the
problem. I was just suggestiing this as a way for you to figure out what
your expression's problem was.