By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
426,011 Members | 1,001 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 426,011 IT Pros & Developers. It's quick & easy.

Access error with calculated field

P: 24
Here is my calculation:

=DateAdd("d",-1,DateAdd("d",56,DateAdd("d",-(IIf(Weekday([Cert_Date])=1,"0",Weekday([Cert_Date]-1))),[Cert_Date])))

I get "#Error" in the field when displayed. However, when I enter the [Cert_Date] for the calculation, it does calculate. So why is the error showing?

Thanks!
Aug 5 '10 #1
Share this Question
Share on Google+
2 Replies


Expert 100+
P: 107
It seems Cert_Date can't be null for the formula to work.

Try:
Expand|Select|Wrap|Line Numbers
  1. iif(isdate([Cert_Date]),DateAdd("d",-1,DateAdd("d",56,DateAdd("d",-(IIf(Weekday([Cert_Date])=1,"0",Weekday([Cert_Date]-1))),[Cert_Date]))),Null)
Aug 5 '10 #2

P: 24
THANKS!!!!!!!!!!!!

Dave
Aug 5 '10 #3

Post your reply

Sign in to post your reply or Sign up for a free account.