Hi
I have a form and a report, both based on the same query.
I have placed a button on the form to open the report to show only the current report, with the following code
DoCmd.OpenReport stDocName, acPreview, , "NUMERO = " & Me.NUMERO
Now, I want to change the field to filter from NUMERO to NUMSP. NMSPO is actually the primary key in the original table. Th is primary key is a concatenation of several values.
When I change the code so that the criteria is the NUMSP value, like thi
DoCmd.OpenReport stDocName, acPreview, , "NUMSP = " & Me.NUMSP
it won't work, it'll prompt me for "SP" and another value, than it will show a blank report.
Can anyone help? I am very lost at this point and searching Google does not seem to bring up similar questions elsewhere...
Thanks!
I have a form and a report, both based on the same query.
I have placed a button on the form to open the report to show only the current report, with the following code
DoCmd.OpenReport stDocName, acPreview, , "NUMERO = " & Me.NUMERO
Now, I want to change the field to filter from NUMERO to NUMSP. NMSPO is actually the primary key in the original table. Th is primary key is a concatenation of several values.
When I change the code so that the criteria is the NUMSP value, like thi
DoCmd.OpenReport stDocName, acPreview, , "NUMSP = " & Me.NUMSP
it won't work, it'll prompt me for "SP" and another value, than it will show a blank report.
Can anyone help? I am very lost at this point and searching Google does not seem to bring up similar questions elsewhere...
Thanks!