A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Setting Up & Running Reports
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

#NAME? Error on Form



 
 
Thread Tools Display Modes
  #1  
Old July 23rd, 2007, 04:51 AM posted to microsoft.public.access,microsoft.public.access.forms,microsoft.public.access.formscoding,microsoft.public.access.queries,microsoft.public.access.reports
Rob B.[_2_]
external usenet poster
 
Posts: 29
Default #NAME? Error on Form

I want some form fields to automatically populate with data once another
field on the form is filled in. Specifically, I want a city and state to
fill in automatically once a zip code is entered.

My table tblZipCodes has 3 fields: fldZip, fldCity, and fldState

My query qryZipCodes has an expression, expCitySt, which combines fldCity
and fldState, which looks like, expCitySt: [fldCity] & ", " & [fldState].
The expression produces the desired result in the query

On the form when I enter a valid Zip Code from tblZipCodes, the field that
points to qryZipCodes.expCitySt, just returns #NAME?.

Ideas?


Rob B.
  #2  
Old July 23rd, 2007, 05:38 AM posted to microsoft.public.access,microsoft.public.access.forms,microsoft.public.access.formscoding,microsoft.public.access.queries,microsoft.public.access.reports
UpRider
external usenet poster
 
Posts: 259
Default #NAME? Error on Form

Rob, there's a problem with zipcode city-state lookups. The problem is that
zipcodes cover more than one city, or in other words, several cities can
have the same zipcode.
Download and look at http://www.dbtc.org/zipmdb\ziplookup.zip
This is a small db that demonstrates how to automatically enter the city and
state when the zipcode is typed in a form. If the zip covers more than one
city, a popup lists the cities and asks you to choose one.

HTH, UpRider

"Rob B." wrote in message
...
I want some form fields to automatically populate with data once another
field on the form is filled in. Specifically, I want a city and state to
fill in automatically once a zip code is entered.

My table tblZipCodes has 3 fields: fldZip, fldCity, and fldState

My query qryZipCodes has an expression, expCitySt, which combines fldCity
and fldState, which looks like, expCitySt: [fldCity] & ", " & [fldState].
The expression produces the desired result in the query

On the form when I enter a valid Zip Code from tblZipCodes, the field that
points to qryZipCodes.expCitySt, just returns #NAME?.

Ideas?


Rob B.



  #3  
Old July 23rd, 2007, 12:09 PM posted to microsoft.public.access,microsoft.public.access.forms,microsoft.public.access.formscoding,microsoft.public.access.queries,microsoft.public.access.reports
BruceM[_2_]
external usenet poster
 
Posts: 1,763
Default #NAME? Error on Form

Is expCityState included in the form's Record Source (and therefore
available on the form's Field List)? Are you linking to tblZipCode from
your main table, or are you copying the values, or what exactly? In asking
this I assume that there is another table with some kind of personal
information, and that tblZipCode offers a shortcut for including some of the
information.

"Rob B." wrote in message
...
I want some form fields to automatically populate with data once another
field on the form is filled in. Specifically, I want a city and state to
fill in automatically once a zip code is entered.

My table tblZipCodes has 3 fields: fldZip, fldCity, and fldState

My query qryZipCodes has an expression, expCitySt, which combines fldCity
and fldState, which looks like, expCitySt: [fldCity] & ", " & [fldState].
The expression produces the desired result in the query

On the form when I enter a valid Zip Code from tblZipCodes, the field that
points to qryZipCodes.expCitySt, just returns #NAME?.

Ideas?


Rob B.



 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 12:29 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.