home delivery db

J

jbabb

I am trying to process home delivery orders in excel.. I
made a page where when I imput the tel. no. of the
client, his information, if exists, is brought to this
screen form a given db, but I am using FOR and NEXT with
a variable to look for the inputed tel no. in the db in
the correspondin column, the variable being the row no.,
once it is found I bring the rest of the info. to the
main page(address, name, etc.)

I cant use vlookup because if the client does not exist
the cells must be filled by hand, in doing so, I would
erase the vlookp formula.

It is working, the problem is that now it takes quite a
while to find a client since my db is bigger now.

Is there a faster command in excel vb to do this? if so,
how?

Please respond to (e-mail address removed)

thanks
..
 
T

Tom Ogilvy

you might load your db into an array and search the array - or you might
preprocess your db to put selected information in an array, organized to
support fast retrieval/query.

There are many algorithms for doing searches besides doing a for - next loop
through all your data. Binary search comes to mind, but your data (which
may be an extract of your database) would need to be sorted.
 
B

BrianB

Have a look at Find. Type Find in the VB editor then press your F1 key to get Help.


Regards
BrianB
==========================
 

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