This topic is locked

How to Implement Zipcode Lookup

4/10/2016 7:35:12 PM
ASPRunner.NET General questions
R
raymueller authorDevClub member

I am looking for a good way to implement the ability to lookup a zip code in a table and return the city and state associated with that zip code.
I have a table of zip codes including the city and state however I am uncertain how best to have the capability from a form that when a valid zip code is entered that the city and state text fields are filled in using the return results.
I planned on using a stored procedure to perform the data query but the part that I am uncertain with is how trigger the lookup to begin.
My practical knowledge of JavaScript is shaky. I was thinking that a trigger would happen when 5 digits are entered into the zip code textbox or when the text box loses focus. Of course I can include a button that will initiate the zip code lookup query.
What would be a good method to implement? Does anyone have a similar example or code how this was implemented?
Thank you

Ray

Sergey Kornilov admin 4/11/2016

What's about using autofill option?
http://xlinesoft.com/asprunnernet/docs/lookup_wizard.htm

'Autofill' section
Zip code field needs to be setup as a lookup wizard, probably 'Edit box with AJAX popup' will work the best.

R
raymueller authorDevClub member 4/11/2016

Sergey
I think that is a brilliant idea. Clean and simple. I have been accustomed to accomplishing this as an external step.
Thank you.

Ray



What's about using autofill option?
http://xlinesoft.com/asprunnernet/docs/lookup_wizard.htm

'Autofill' section
Zip code field needs to be setup as a lookup wizard, probably 'Edit box with AJAX popup' will work the best.