473,669 Members | 2,458 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Record Search through Combo Box problem

Hi,
I have a table of around 1000 rows; patient records. Each row is
individually defined by a Patient ID number which is my primary key.

I have made a simple form to display patient information for the
secretaries working in the office. I would like them to be able to
easily search through all the records using a combo box, that they can
just type in the person's name. I have managed to make it work so far
as when the last name is typed in the, the first person with that last
name comes up (first person being the person with the lowest Patient ID
number).

I would like to be able to alphabetize the combo box list, because now
it's ordered by the Patient ID number, thus the names are nothing but a
jumble in the combo box. I cannot make last names the primary key
because multiple people have the same last name.

How can I easily create a combo box that is alphabetically ordered, can
be typed into, and will display a record on the form when it is clicked
on in the combo box?

I'm a newbie at queries as well.

Thanks all!

Jan 5 '07 #1
3 2470
MF:

In the design of your form, go to the Properties of your ComboBox. On
the Data tab, click in the Row Source field. You should see a button
with 3 dots on it to the right of the Row Source. Click that, which
takes you to the query for your ComboBox. In your PatientName column,
change the Sort to Ascending. Then close the query and click Yes to
update the property. That should do it!

HTH,
Jana
mf193 wrote:
Hi,
I have a table of around 1000 rows; patient records. Each row is
individually defined by a Patient ID number which is my primary key.

I have made a simple form to display patient information for the
secretaries working in the office. I would like them to be able to
easily search through all the records using a combo box, that they can
just type in the person's name. I have managed to make it work so far
as when the last name is typed in the, the first person with that last
name comes up (first person being the person with the lowest Patient ID
number).

I would like to be able to alphabetize the combo box list, because now
it's ordered by the Patient ID number, thus the names are nothing but a
jumble in the combo box. I cannot make last names the primary key
because multiple people have the same last name.

How can I easily create a combo box that is alphabetically ordered, can
be typed into, and will display a record on the form when it is clicked
on in the combo box?

I'm a newbie at queries as well.

Thanks all!
Jan 5 '07 #2
WOW...thank you!!! Worked perfectly. I feel pretty stupid, I was
messing with this for hours trying to write sortable queries. Thanks so
much Jana.

On Jan 5, 2:59 pm, "Jana" <Bauer.J...@gma il.comwrote:
MF:

In the design of your form, go to the Properties of your ComboBox. On
the Data tab, click in the Row Source field. You should see a button
with 3 dots on it to the right of the Row Source. Click that, which
takes you to the query for your ComboBox. In your PatientName column,
change the Sort to Ascending. Then close the query and click Yes to
update the property. That should do it!

HTH,
Jana

mf193 wrote:
Hi,
I have a table of around 1000 rows; patient records. Each row is
individually defined by a Patient ID number which is my primary key.
I have made a simple form to display patient information for the
secretaries working in the office. I would like them to be able to
easily search through all the records using a combo box, that they can
just type in the person's name. I have managed to make it work so far
as when the last name is typed in the, the first person with that last
name comes up (first person being the person with the lowest Patient ID
number).
I would like to be able to alphabetize the combo box list, because now
it's ordered by the Patient ID number, thus the names are nothing but a
jumble in the combo box. I cannot make last names the primary key
because multiple people have the same last name.
How can I easily create a combo box that is alphabetically ordered, can
be typed into, and will display a record on the form when it is clicked
on in the combo box?
I'm a newbie at queries as well.
Thanks all!
Jan 5 '07 #3
LOL No problem. Glad it worked for ya!

Jana

mf193 wrote:
WOW...thank you!!! Worked perfectly. I feel pretty stupid, I was
messing with this for hours trying to write sortable queries. Thanks so
much Jana.

On Jan 5, 2:59 pm, "Jana" <Bauer.J...@gma il.comwrote:
MF:

In the design of your form, go to the Properties of your ComboBox. On
the Data tab, click in the Row Source field. You should see a button
with 3 dots on it to the right of the Row Source. Click that, which
takes you to the query for your ComboBox. In your PatientName column,
change the Sort to Ascending. Then close the query and click Yes to
update the property. That should do it!

HTH,
Jana

mf193 wrote:
Hi,
I have a table of around 1000 rows; patient records. Each row is
individually defined by a Patient ID number which is my primary key.
I have made a simple form to display patient information for the
secretaries working in the office. I would like them to be able to
easily search through all the records using a combo box, that they can
just type in the person's name. I have managed to make it work so far
as when the last name is typed in the, the first person with that last
name comes up (first person being the person with the lowest Patient ID
number).
I would like to be able to alphabetize the combo box list, because now
it's ordered by the Patient ID number, thus the names are nothing but a
jumble in the combo box. I cannot make last names the primary key
because multiple people have the same last name.
How can I easily create a combo box that is alphabetically ordered, can
be typed into, and will display a record on the form when it is clicked
on in the combo box?
I'm a newbie at queries as well.
Thanks all!
Jan 5 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
4749
by: Skully Matjas | last post by:
I am using the following code (created by the wizard) to allow to bring my form to a particular entery. But when I edit the entery (ex: put new information into a blank cell), it puts that record onto the bottom of the list (even though it keeps its record number). Also, There are certin names that i click on the list, and it will not bring it up, rather it brings to the first record (no matter how many times i try going to that...
3
2292
by: J | last post by:
I've moved the database tables from the .mdb file to Sql Svr and now I have an *intermittent* problem. When I select a record from a combo box, it will intermittently pull up the wrong record. The code that does the search is below. I have a column named 'ProsId' that is a unique number (identity column). The error -- when it happens -- seems to only happen on higher ProsId numbers. At first it appeared to me as some sort of data...
8
12090
by: Zlatko Matiæ | last post by:
There is a form (single form) and a combobox. I want that current record of the form is adjusted according to selected value in the combobox. Cuurrent record should be the same as the value in the combobox. What is the solution? Thank you in advance.
0
1262
by: Kaur | last post by:
Hi, I am having problem trying to go to same record when I close 3rd form. I have a form called frmDepartment. This form has a list box that displays all the departments. Clicking on one of the departments opens up second form called frmEmployees. This form displays all the employees for the department selected in frmDepartment. This form has an unbound list box which retreives all the values from a query and displays all the names of...
6
2739
by: AA Arens | last post by:
Hi, I have a database with 2 main forms. Contacts and companies. I share the base with two others via LAN. On the companies form I have buttons to navigate throught the records (>400). We are mostly handling let say 5 companies. Every time I have to navigate or choose the find record button to get the right company. I am looking fo a feature to have listed in a combo list the last 5 visited records ("recently visited records").
6
6921
by: San | last post by:
Hey, I need to create a form with several text boxes in which users type in key words, press a command button on the form and it opens a matching record. Thanking you in advance.
1
1663
by: asavu | last post by:
Hello, I'm somewhat new to this, and I definately need some help. I have a db for a small business, and I have a main form, Customer Info, which has a subform Appliance Info, which has a subform Service Call Info... these three forms are linked, and I run into a problem when I try to search through records. I set up a different form where the user can select a customer, after which he can either push a button and using that customer's...
1
1388
by: BayZee | last post by:
I have a main form with a serach box and bound record boxes. When user enters criteria in a search box, the new form pops up that has a combo box with the list of accounts that satisfy search criteria. What I am having a problem with is to implement the following: After selecting an account in a combo box, the initial main form should display that record in bound boxes. It's been such a hurdle for me, I spent days and cannot figure out how to...
6
2309
by: MyWaterloo | last post by:
''''''''''''''''''''''''''''''''''''''''''' ' The AfterUpdate event procedure used in ' ' the Find Customer combo box search. ' ''''''''''''''''''''''''''''''''''''''''''' 'Moves to Customer Name text box and 'finds the record of whatever name 'is selected in the combo box DoCmd.ShowAllRecords Me.OrderDate.SetFocus
0
8465
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8383
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8895
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
8588
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8658
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7407
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6210
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5682
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
2
2032
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.