Question : MS Access + You entered an expression that has no value

I just need to trap this message and make it invisible to the user!

Answer : MS Access + You entered an expression that has no value

See here:
http://office.microsoft.com/en-us/access/HA011814481033.aspx
And see if this helps you resolve the issue.

For example, a controlsource using a function that will produce and error, can generate #Error
For example:
=DateDiff("www",2,#1/1/2009#)
...will produce:  #Error
...because "www" is not a valid argument in the DateDiff Function.

Abs([FirstName]), will also generate #Error because the Abs() function needs a number, and [FirstName] is a string.

Obviously since you did not list any info on your system, only you can determine why the error occurs.



Yes, *ONLY* if you have done everything possible to avoid the error in the first place.
You can use something like this:
    IIF(IsError(Abs([FirstName])),"No Data",Abs([FirstName]))
But even here you can see that the basic formula is flawed, so this is really NOT a solution in this case.

It cannot be stressed enough...
  The goal is to avoid the error form happening in the first place, not trap the error or display something else.

Keep us posted...
;-)

JeffCoachman
Random Solutions  
 
programming4us programming4us