So I'm trying to add a field with an expression on a report. The current layout has a "Certificate Number" and a "Certificate Date", and I need to add an "Expiration Date" which will be one year after the "Certificate Date".
If I use =DateAdd(yyyy, 1, [CertificateDate]) I typically get a #Name? error.
There is another location in the database that shows the cert #, cert date, and expiration date on a form - so I think, "maybe I'll try to pull the data from somewhere that has the expression working correctly". So I try =[Forms]![NISTCertificate]![ExpirationDate] and get the same #Name? output. HOWEVER, if I highlight the date on the form, then run the expression on the report, it fills in the date I have selected on the form. So now I'm confused because the only way I've been able to get this to work is to open the "form", select the date I want, then open the "report" and run the expression by switching from Design View to Report View.
I should add each NISTCertificate number has a corresponding Certificate Date, so maybe I'm trying to write an expression based on the output of another expression and that is causing a problem, but I'm just not sure. I've spent the last week trying to figure this out and haven't made much progress.
I am not very fluent with Access, and someone else built this database before I came to start working on it. Any assistance is greatly appreciated.
If I use =DateAdd(yyyy, 1, [CertificateDate]) I typically get a #Name? error.
There is another location in the database that shows the cert #, cert date, and expiration date on a form - so I think, "maybe I'll try to pull the data from somewhere that has the expression working correctly". So I try =[Forms]![NISTCertificate]![ExpirationDate] and get the same #Name? output. HOWEVER, if I highlight the date on the form, then run the expression on the report, it fills in the date I have selected on the form. So now I'm confused because the only way I've been able to get this to work is to open the "form", select the date I want, then open the "report" and run the expression by switching from Design View to Report View.
I should add each NISTCertificate number has a corresponding Certificate Date, so maybe I'm trying to write an expression based on the output of another expression and that is causing a problem, but I'm just not sure. I've spent the last week trying to figure this out and haven't made much progress.
I am not very fluent with Access, and someone else built this database before I came to start working on it. Any assistance is greatly appreciated.
Last edited: