A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Database Design
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Search for Names in DB



 
 
Thread Tools Display Modes
  #1  
Old January 3rd, 2009, 08:59 PM posted to microsoft.public.access.tablesdbdesign
RyGuy
external usenet poster
 
Posts: 40
Default Search for Names in DB

I hope this is the correct category for this question. I have a generic
Access DB which allows a user to input a unique number into a TextBox and
then search for this number in a Table. The code works great, I'm just
thinking of ways that I may change it to help a friend with a project.
Basically, my friend works at a hospital and he wants to start using Access
to warehouse information for patients. IDs will probably be used for patient
record keeping. However, I am thinking of adding a feature to look up a
patient based on name (which will be easier to remember than an ID). Anyway,
my questions is this: is there a good sample DB out there somewhere, with VBA
code, etc, that demos how to search for a name, such as David, and then
return all matches so the user can identify the appropriate individual?
Then, when the user selects the appropriate individual he/she see all related
information for this specific person. I have a DB that allows a user to
search for a unique ID, and then all records are returned when the VBA fires.
If I change the code a bit, and search by name, I can find David, and I get
the first match, but I can't see any other person named David in my DB.

Thanks,
Ryan--
  #2  
Old January 3rd, 2009, 10:06 PM posted to microsoft.public.access.tablesdbdesign
Steve[_57_]
external usenet poster
 
Posts: 598
Default Search for Names in DB

Create an unbound combobox based on a query. The query needs to have an ID
field first then all the fields you might search on. In your example you
need a first name field. The criteria of the search field needs to be set
by an unbound textbox. You enter the criteria in the textbox then open the
combobox and you will then see all Davids. You click on the one you want and
code in the AfterUpdate event (which you wrote) will take you to the record
of the David you selected.

Steve


"RyGuy" wrote in message
...
I hope this is the correct category for this question. I have a generic
Access DB which allows a user to input a unique number into a TextBox and
then search for this number in a Table. The code works great, I'm just
thinking of ways that I may change it to help a friend with a project.
Basically, my friend works at a hospital and he wants to start using
Access
to warehouse information for patients. IDs will probably be used for
patient
record keeping. However, I am thinking of adding a feature to look up a
patient based on name (which will be easier to remember than an ID).
Anyway,
my questions is this: is there a good sample DB out there somewhere, with
VBA
code, etc, that demos how to search for a name, such as David, and then
return all matches so the user can identify the appropriate individual?
Then, when the user selects the appropriate individual he/she see all
related
information for this specific person. I have a DB that allows a user to
search for a unique ID, and then all records are returned when the VBA
fires.
If I change the code a bit, and search by name, I can find David, and I
get
the first match, but I can't see any other person named David in my DB.

Thanks,
Ryan--



  #3  
Old January 3rd, 2009, 11:15 PM posted to microsoft.public.access.tablesdbdesign
Pete D.[_3_]
external usenet poster
 
Posts: 488
Default Search for Names in DB

One warning, Access isn't secure enough to store patients data and comply
with Fed law. That said Allen Browne has a search form that is pretty cool
and there are many others but Allen tends to come up before the others in my
favorites. Google search MS Access Search Form to see many options.

http://allenbrowne.com/ser-62.html

"RyGuy" wrote in message
...
I hope this is the correct category for this question. I have a generic
Access DB which allows a user to input a unique number into a TextBox and
then search for this number in a Table. The code works great, I'm just
thinking of ways that I may change it to help a friend with a project.
Basically, my friend works at a hospital and he wants to start using
Access
to warehouse information for patients. IDs will probably be used for
patient
record keeping. However, I am thinking of adding a feature to look up a
patient based on name (which will be easier to remember than an ID).
Anyway,
my questions is this: is there a good sample DB out there somewhere, with
VBA
code, etc, that demos how to search for a name, such as David, and then
return all matches so the user can identify the appropriate individual?
Then, when the user selects the appropriate individual he/she see all
related
information for this specific person. I have a DB that allows a user to
search for a unique ID, and then all records are returned when the VBA
fires.
If I change the code a bit, and search by name, I can find David, and I
get
the first match, but I can't see any other person named David in my DB.

Thanks,
Ryan--



  #4  
Old January 3rd, 2009, 11:37 PM posted to microsoft.public.access.tablesdbdesign
RyGuy
external usenet poster
 
Posts: 40
Default Search for Names in DB

Excellent!! Thanks for these ideas, Steve and Pete!!
Regards,
Ryan---


"Pete D." wrote:

One warning, Access isn't secure enough to store patients data and comply
with Fed law. That said Allen Browne has a search form that is pretty cool
and there are many others but Allen tends to come up before the others in my
favorites. Google search MS Access Search Form to see many options.

http://allenbrowne.com/ser-62.html

"RyGuy" wrote in message
...
I hope this is the correct category for this question. I have a generic
Access DB which allows a user to input a unique number into a TextBox and
then search for this number in a Table. The code works great, I'm just
thinking of ways that I may change it to help a friend with a project.
Basically, my friend works at a hospital and he wants to start using
Access
to warehouse information for patients. IDs will probably be used for
patient
record keeping. However, I am thinking of adding a feature to look up a
patient based on name (which will be easier to remember than an ID).
Anyway,
my questions is this: is there a good sample DB out there somewhere, with
VBA
code, etc, that demos how to search for a name, such as David, and then
return all matches so the user can identify the appropriate individual?
Then, when the user selects the appropriate individual he/she see all
related
information for this specific person. I have a DB that allows a user to
search for a unique ID, and then all records are returned when the VBA
fires.
If I change the code a bit, and search by name, I can find David, and I
get
the first match, but I can't see any other person named David in my DB.

Thanks,
Ryan--




  #5  
Old January 4th, 2009, 12:44 AM posted to microsoft.public.access.tablesdbdesign
John W. Vinson
external usenet poster
 
Posts: 18,261
Default Search for Names in DB

On Sat, 3 Jan 2009 12:59:00 -0800, RyGuy
wrote:

Basically, my friend works at a hospital and he wants to start using Access
to warehouse information for patients.


Let me amplify Pete's warning: patient data can be stored in Access, but you
should really read up on the very stringent HIPAA patient-privacy regulations,
unless you have $50,000 or so sitting around unused to pay the fines for
violations.
--

John W. Vinson [MVP]
  #6  
Old January 6th, 2009, 03:15 AM posted to microsoft.public.access.tablesdbdesign
Jame
external usenet poster
 
Posts: 9
Default Search for Names in DB

I think it would be easier to create a form with tabs on it. Basic
information could be on the first tab or on the form without a tab control.
You can filter by form or using the find command and then filtered. You will
only see the David's and can flip through the different ones to find the
correct person.

"Steve" wrote:

Create an unbound combobox based on a query. The query needs to have an ID
field first then all the fields you might search on. In your example you
need a first name field. The criteria of the search field needs to be set
by an unbound textbox. You enter the criteria in the textbox then open the
combobox and you will then see all Davids. You click on the one you want and
code in the AfterUpdate event (which you wrote) will take you to the record
of the David you selected.

Steve


"RyGuy" wrote in message
...
I hope this is the correct category for this question. I have a generic
Access DB which allows a user to input a unique number into a TextBox and
then search for this number in a Table. The code works great, I'm just
thinking of ways that I may change it to help a friend with a project.
Basically, my friend works at a hospital and he wants to start using
Access
to warehouse information for patients. IDs will probably be used for
patient
record keeping. However, I am thinking of adding a feature to look up a
patient based on name (which will be easier to remember than an ID).
Anyway,
my questions is this: is there a good sample DB out there somewhere, with
VBA
code, etc, that demos how to search for a name, such as David, and then
return all matches so the user can identify the appropriate individual?
Then, when the user selects the appropriate individual he/she see all
related
information for this specific person. I have a DB that allows a user to
search for a unique ID, and then all records are returned when the VBA
fires.
If I change the code a bit, and search by name, I can find David, and I
get
the first match, but I can't see any other person named David in my DB.

Thanks,
Ryan--




 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 09:41 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.