[AccessD] Multiple Table Search

DWUTKA at marlow.com DWUTKA at marlow.com
Tue Jul 27 10:33:14 CDT 2004


(Here we go, posting this under the right subject this time!)


Okay, here ya go.  I built this into a form, because it uses a lot of
'techniques' to get things done. (Class modules, collections, callback
functions (for the list box)), along with all of the associated properties
that need to be set to get things done.  So instead of trying to explain how
to build the form, I'm just posting a link to download it.  Right now, my
DSL is down (in case anyone wondered why the archives on my site weren't
there.....), it will be back up Thursday...so within a few days of that, I
will try to remember to put this file on my website.
(http://www.wolfwares.com)

Until then, I put it on my company's website, for download.

http://www.marlow.com/FindAllData.zip

The zipped database has a form, query, and class module.  Just import all
three into whatever database you want.  Open the form, enter the search
criteria, and click the button.  All applicable hits will be displayed in
the listbox.  You can then double click the listbox to display either the
particular record (if a primary key for that table exists), or for all of
the results off of that table.

Boy, that was actually fun to build!

Drew

FYI:  This code only searches for text, in text and memo fields.  It also
automatically puts astericks around the search criteria, so if you want to
put astericks inside the criteria, go ahead, but they're not necessary on
the outside.  If you want to search number fields, the code could be
modified to do that.  Actually, if there is enough of a request for it, I
could modify the search form to have different search boxes (text, currency,
date/time, etc).  Finally, and this is IMPORTANT, the code uses ADO.  The
sample I built is in 97, which has DAO set by default, but if you use A2k,
make sure you have DAO selected.





More information about the AccessD mailing list