postcode

T

T3E

hi, i've got a form with a field named postcode, and i wanna use this field
as the criteria for the query. so when the query is run the postcode entered
in the form field is searched up.

also i want to be able to enter half the postcode and the query should
retrieve full postcodes. e.g. when i enter e11 i want it to display all e11
postcodes, even those that have the full postcode such as e11 3rt, e11 5ps.
 
A

Al Campagna

T3E,
Let's say your form (ex. name frmMyForm) has a text control (name
PostCode), where partial or full postal codes will be entered for purposes
of filtering a query.
Use the LIKE operator in your criteria gaianst the PostCode field in your
query...
Like Forms!frmYourForm!PostCode & "*"
This will deliver the correct record/s, whether a full or partial
PostCode is entered on the form.

--
hth
Al Campagna
Microsoft Access MVP
http://home.comcast.net/~cccsolutions/index.html

"Find a job that you love... and you'll never work a day in your life."
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top