Lookup List

Brutal

Cannis
Local time
Today, 03:24
Joined
May 7, 2002
Messages
25
Hello

I have a table with part numbers in it, I would like to have a field in a form that a user can type in, as he does so matching partnumbers will appear in a list in another field.

Eg

user types abc
list shows abcdef, abcdfg, abcd12 etc.

the list is to be non editable but if the user clicks on an item in the list the rest of the data eg, part number, description etc will appear in another field

Could someone please help me out on this one.

Many Thanks

Paul
 
This is doable, but will require some coding.

First, place some code in the Change event of the text box that the user types into. This way, as the user types (or deletes) each character, you can run some code. That code will consist of searching your data tables (or queries) for matches, then updating the list box of matching part numbers.

Second, create the list box that will hold matching part numbers. Don't worry about setting the control source or rowsource of the listbox, you will do that from the code mentioned above.

Third, attach code to the On Click event of your list box. That code will provide more information in additional fields about the selection the user clicked.
 
Hello
You need to built combobox control which based on a query contains all fields you interesting in.
Use After_Update() event to assign field values to other textbox bounded to your table fields.
Use method Column(0), Column(1) etc. belongs to your combobox for this purpose.

Igor.
 
Thanks to both of you for replying

DCX693, what you have written appears to be spot on, aside from that I have no vb coding experience whatsoever, the few databases that I have created although quite comprehensive were all standard access stuff. Any hints on the code required.

Many thanks

Paul
 
Thankyou Thankyou Thankyou

Fizzio
What more can I say

Thankyou

Paul
 
:o
Cheers guys - one of my better demos - Mile-O has a hard drive full of them by the looks of it though!
 
Paul

Here is another variation to what has been posted.


Cheers!!!!


Lou:D :cool:
 

Attachments

Thanks Lou
thats very good of you I'll see what I can learn from it

Paul
 
Fizzio said:
Try this demo, I think it will do exactly what you want.

If my search is numeric it is the same procedure.

that mean, I need on Part number. Am I doing the same procedure.

Tks
 

Users who are viewing this thread

Back
Top Bottom