Minggu, 03 Juli 2022

Re: [MSAccessProfessionals] Textbox is populated with the "#NAME?" error code. after upgrading computers

hii Sarah,

I am also using 2016. I created an example table and that expression works for me even though it could be better written like this:

=DFirst("[city] & ' ' & [state] & ' ' & Left( nz( [postalcode],''),5)","Provider")

Inside the double quotes " are single quotes '

~~~

There could be something else on the form that is really causing the issue.

Since the expressions with multiple DLookups are resulting in the error, perhaps rewrite them to be like the above? NZ shouldn't be necessary if there is data, but I find that when using a function that needs a string like Left, it behaves better.

~~~

> "The BE and FE are both in Access 2003. The user is using Access 2016 run time."

does it work ok for YOU? Is it just this user who is having an issue? Runtime can do quirky things, and I can't test it

~~~

please, when you respond, choose to keep previous message
so we don't lose what has already been written, thanks

kind regards,
crystal


On 7/3/2022 6:22 PM, novice012000 wrote:
I added Option Explicit and compiled. There are no errors and no missing References

Example of text box that works:
=DLookUp("[name]","Provider","")

Example of text box that does not work:
=DLookUp("[city]","Provider","") & " " & DLookUp("[state]","Provider","") & " " & Left$(DLookUp("[postalcode]","Provider",""),5)

All text boxes that are comprised of more than one input field are resulting in #Name? error in Access 2016.

The BE and FE are both in Access 2003. The user is using Access 2016 run time.

Sarah

Tidak ada komentar:

Posting Komentar