Forms :: Combo Box With Values Based On Another Combo Box
Jun 25, 2013
I have a main form that filters data in a subform based on selections via combo box users make on the main form.
So I have the 'department' and 'manager's name'. If someone selects 'Human Resources' from 'department' combo box, then I only want to see the managers that are in the Human Resources departement when I drop down the combo box for 'manager's name'. Currently I'm seeing all the managers and a user can select a manager that is not in human resources and get no data returned. I prefer for him to get a list of those that are in that department only. The source of the combo box is a query.
I got it! Found here: [URL] ....
View Replies
ADVERTISEMENT
Sep 7, 2006
Thanks in advance for your help.
I would like to set up rules/constraints such that the value selected in combo box A determines the available values in combo box B. For example, "Combo box A" is bound to the [PartnerType] field and "Combo box B" is bound to the [PartnerRole] field. Let's say that the two choices in Combo Box A are "LLC", "LP", and "Corporation". There are 5 possible choices in Combo Box B: "X", "Y", "Z", "Q", and "U". If a user selects "LP" in Combo Box A, I would like Combo Box B to only show choices "X" and "Y". And if a user selects "LLC", only choices "Y", "Z", "Q", and "U".
Similarly, I would like to set this up so that Combo Box B is not initially visible--it becomes visible when a user selects "LLC" or "LP". If a user selected "Corporation", Combo Box B would remain hidden.
View 2 Replies
View Related
Jun 6, 2014
I am having issues with my combo box populating values based on the selection from another combo box.
Database : contains 2 tables: Staff_List, Level_Type and a form called frm_Test
The first combobox cboLevel gets its value from the Level_Type table with the select statement SELECT [Level_Type].[ID], [Level_Type].[Level_Type] FROM level_Type;
The values to be displayed on the second combobox cbo_Name is expected to be dependent on the Level selection made from the first combobox i.e if Level 1 is selected in cboLevel then only Names of people in Level 1 will be displayed in second combobox.
The select statement I put there is SELECT Staff_List.ID, Staff_List.Staff_Name
FROM Staff_List
WHERE ((([Staff_List]![Level])=[Forms]![frm_test]![cboLevel]));
This is not displaying anything in the second combobox after I tried it in the Form view, just empty.
View 3 Replies
View Related
Aug 25, 2014
Field B is a combo with the options of : 100% Availability, 75% Availability, 50% Availability, 25% Availability, OR Not Available
If I choose "Present" in Field A, I want the "Not Available" value to disappear as an option.
View 2 Replies
View Related
Feb 6, 2013
I have a form, with a subform and another subform
Once a supplier name is selected from the combo box i only want it displayed that suppliers products in the subform, subform. (products combo box) I can get a basic query to show these results but can get the combo box to do the same.
The design screen is also attached below ....
View 14 Replies
View Related
Aug 5, 2013
I have several comboboxes (6) on my form.How to populate these comboboxes with values depending on selected value in previous combobox.
Example.Lets say that you select value "Audi" in combobox 1, then available values in combobox 2 should be "A4","A6","TT" etc. and if you selected "BMW" in combobox 1, then available values in combobox 2 should be "3-series", "5-series" etc...
View 1 Replies
View Related
Mar 31, 2014
I have a form that currently uses a "catch all" table for listing available equipment to choose from for an equipment field. I call it tblEquipment. What I want to do is to make it so when I type a name in (1 of 35) in one field of the current record, the record source for the equipment field immediately looks at a different table that has equipment available only for that name. To do this I plan on making 35 different tables with limited data originally found in tblEquipment. I would call these tblEquipment1, tblEquipment2, etc. I do not use a sub form, nor do I want to.
So my questions are:
1) can this be done
2)If it can be done, how can I do it?
View 3 Replies
View Related
May 21, 2014
I'm looking for a way to have a text box auto fill based on the selection of a combo box on the same form. I cannot use the method i find all over the internet of using multiple columns in the combo box and basing the text box on that because the combo box already has multiple columns being used to determine its own possibilities and other combo box possibilities.
I would really just like the text box to work like this, but im still kinda inexperienced in VBA...
If combo box is "F004-001", then text box is "237"
If combo box is "F004-003", then text box is "280"
I know how to add in an "after update" thing, but i do not know how to do If/then statements.
View 1 Replies
View Related
Nov 29, 2014
I'm trying to build a database for daily work. My work in daily basis I have to fill all condition for several items.
We have two areas, with two locations under each area, and three systems under each location and each system contain more than 500 items.
I created all tables and fill by all information:
1-Table 1: Area 1, Area 2, Area 3, Area 4, Area 5, Area 6.
2-Table 2: Location 1, Location 2.
3-Table 3: System 1, System 2, System 3.
4-Table 4: all items under System 1-1-1
5-Table 4: all items under System 1-1-2
[Code] ....
Last table will be LogBook which will be as follow:
date l time l area l location l system l item l Conition1 l Conition2 l Conition3
My question regarding to the form of the above table:
How can I make a combo box for area field and when I select for example area1 will appear only the locations which under area1 in location field, and when I select location1 for example will appear only the systems under location1 in system field, and when I select system1 one for example will appear only items under system 1.Combo box list will be based on the selection in previous combo box and so on.
View 3 Replies
View Related
Jun 3, 2014
I am trying to select a value from one combo box and on the basis of this selection the other combo box show only those values which have link to the value I have selected.
View 14 Replies
View Related
Jun 4, 2013
I have been creating a form, based on only one table. Here I am displaying data as text boxes and subfrom from the same table. At the beginning, I was interested in controlling the display of the data according to the combo box (in this case is the PO number). Now, I would like to add another combox box which is the year (I have a column with the date, and also I have a column that shows only the years digits in my table) Also, I have a subform that display the data from the same table specifics records that I want. It means that I want to pick the year first, and then in the combox box of po number shows only option of that year, and hence the text boxes and subforms change accordingly to the two combox boxes.
View 2 Replies
View Related
Dec 23, 2014
I have two comboboxes on my form one 'cboMake' and the other 'cboModel'. Both of their values are stored in individual columns ('Make' and 'Model') in the same table 'tblStock'. What I would like to achieve is when I select a value from 'cboMake' that 'cboModel' will filter it's data values to only display Models that are linked to Make i.e. if I select Make Logitech I would like it to only display the following results for Model: 'K120', 'K200', 'G500', 'G502' etc. and not display any of the other values associated with another Make.
View 6 Replies
View Related
Dec 9, 2005
Hello,
I'm stuck! I want to create a form which has a combo box where you select
someone's name, and their address appears in another text box on the same form. The names and addresses are in a table called "cardholders".
I'm doing separate combos for first name, surname cos I think that's the only
way you can do it.
The fields in the table are credit_add, credit_name & credit_surname. The combos are called "cardholder name" "cardholder surname" etc. This is the code in the text box where I want the address to appear:-
=DLookUp("[credit_add]","cardholders","[credit_name] = '" & [cardholdername] & "' And [credit_surname] = " & [cardholdersurname])
Can anyone help?
Thanks.
View 3 Replies
View Related
May 20, 2014
I am trying to write a query that gets all the telephone hours from a worker done under supervision in a town (qry_svhoursbytown). I have a table that has the workers details, including town (Crisis_support_workers), then another table that has what hours each worker has done (Supervision_Hours). The town is selected from a combo box on the form (frmSearch), under the heading �total hours by location�.
I try and select Bathurst then press recalculate results and in the text box next to supervision hours, it says 66, but if you look in the Supervision_Hours table, there is only 11 hours for the workers that are in Bathurst.
In the query, I have the sum total of the hours field in the Supervision_Hours table, the Town field from the Crisis_support_workers table with the total selected as Where and in that criteria I have [forms]![frmSearch]![ComboTown], then I just have the town field displayed.
What do I need to change to get it to sum correctly?
I have attached the database below so people can take a look.
View 1 Replies
View Related
Sep 25, 2014
I have a combo box which gets its values from sql server using a query which is called "get_query_reason", which works fine. Now I want to update combo box values based on a user selection, st string. Have written the code, but does not work:
Dim qDef As QueryDef
Dim Query As String
Dim st As String
Dim rs As Recordset
st = "SOV"
Set qDef = CurrentDb.QueryDefs("get_query_reason")
[Code]....
View 3 Replies
View Related
Oct 20, 2005
Hi everyone,
I have two combo boxes on the same form bound to a table. I want the contents of the next combo box to change based on the previous combo selection e.g
cboContinent cboCountry
Africa Zambia
Africa Congo
Africa South africa
Europe England
Europe Holland
If I choose Africa in cboContinent, I want to see only Zambia, South Africa and Congo under cboCountry and if I choose Europe I want to see only England and Holland
Thanks
Humphrey
View 1 Replies
View Related
Jul 11, 2012
I'm have quite a difficult time getting a form in Access 2010 to perform the way I would like it to. I have multiple tables that I've created, and a query that contains the data from the various tables. I then ran the form wizard to select the data from the query that I wanted to populate in my form and I've added 2 combo boxes.
What I want to do:
1. I want users to be able to select a category in combo box #1 (example: "Bag")
2. I want users to be able to select a detail in combo box #2 based on the category they selected in combo box #1 (example: Combo box #1, "bag" would populate the following selections for combo box #2: "sandwich" and "tool")
3. I want users to then receive a list of suppliers that provide the product they have selected, either "Bag: Sandwich" or "Bag: Tool"
I have combo box #1 populating a list of categories already. However, I am not able to get combo box #2 to provide choices based on the selection chosen for combo box #1.
View 1 Replies
View Related
Mar 11, 2012
Let's assume we have 3 tables:
Order_Category (Order_Category_ID, Order_Type_Name) with 2 records:
1, Minor
2, Major
Order_Type (Order_Category_ID, Order_Type) with 4 records:
1, Book
1, Pencil
2, Car
2, House
Orders (Order_Category_ID, Order_Type, value) with 2 records:
1, NULL, NULL
1, NULL, NULL
2, NULL, NULL
I want to create a Multiple Items form presenting Orders table with two Combo Boxes:
1. A combo box to select Order_Category_ID.
2. A combo box to select Order_Type. When 1 (Minor) is chosen in the first combo box it should show Book and Pencil, when 2 (Major) is chosen it should show Car and House.
Examples in the Internet show how to do it on a 'single row' forms using the RowSource property. I tried to use a query like:
SELECT Order_Type
FROM Order_Type
INNER JOIN Orders ON Order_Type.Order_Category_ID = Orders.Order_Category_ID
WHERE Order_Category_ID = [comboBoxOrderCategoryID]
But it sets same values for all records in the Multiple Items form and it should return different values in each rows based on value in the first combo box (Order_Category_ID).
View 5 Replies
View Related
Nov 1, 2014
I am new to access. In a form, I have a combo box(combo1) that store values in field(remarks1) in a table.The values in combo box are:
SL
ST
DI
SL + ST
SL + DI
These all values are being saved in remarks1 quiet easily. I have more fields in the table:
SL1
ST1
DT1
SLST1
SLDI1
I want when I selet SL from combo1 it saves SL in remarks1 and save "1" as well in SL1 field.I want to have same result with all five combo1 values
View 2 Replies
View Related
Jul 14, 2014
I have a combo box linked to table shipstatus. This table has 2 columns. ShipCode and ShipName. These values are delivered, on hand, received, returned, warehouse.
I have another table named manifestdetails and a column labeled shipstatus
I would like to create a form where the user can use the combobox selections from the table shipstatus and update the column shipstatus from the manifestdetails table.
View 3 Replies
View Related
Jul 29, 2014
In my subform, I have a field named Container Type (I know you don't need to tell me about Reserve names for Access, but I can't change the names) where when you choose one of the values (a combo box), the values for a second field (Container Code) changes (another combo box) based on the first selection. Then, based on the selection from the second field five other fields are automatically filled in.
Using:
Access 2010
Windows 7
View 14 Replies
View Related
Jun 25, 2013
I'd like to create a combo-box in a database which takes its values from a field in a table in another db. Both of the dbs are on my computer.
How can I do that?
View 6 Replies
View Related
Jan 23, 2006
Hi all!
It's been a while since I've used Access, and I seem to have forgotten this.
I have a form which allows entry of Borrower's details. I have 2 combo boxes on the form.
They are:
cboBorrName
cboLoanSN
Once the user selects the name from the cboBorrName, I want the cboLoanSN to display all loans associated with the Borrower so that they can select the correct loan and add repayment details accordingly.
I have added the following SQL statement as the record source of cboLoanSN
Code:SELECT * from tblBorrower WHERE tblBorrower.fldLoanSN=[Forms]![frmBorrower]![cboBorrName]
I have also added the following code in the After Update event of cboBorrName
Code:Me.cboLoanSN.Requery
However, it doesn't work.
Can someone please help me out?
Thanks a bunch!
View 6 Replies
View Related
Jul 22, 2014
I've used this guide [URL] .... to only show unique values in a combo box. I can't get it to work, it just shows a load of blank values. If I run the expression builder part from the background, it works but it doesn't work in the combo box. Not sure what I can post to give more details?
View 13 Replies
View Related
Apr 4, 2013
I have a form that has a combobox with table names in it. I want to execute a very complicated SQL statement but I want to put the table name (from the combobox) into the SQL statement. I'm planning on making a button to do this, but I don't know how to put the SQL statement in VBS which would use the combobox value as the table name in the SQL statement.
View 2 Replies
View Related
Dec 3, 2013
I have built a database that is fed from tables provided from outside computer systems, so the architecture isn't exactly how I would design it.
I am trying to use a combo box on a form to quickly jump to a specific department. I have about 130 personnel that are assigned to 10 different departments. I have to use a subform to update the position info vs. the personal info.
The combo box works, but I can't get it to display each department once. It shows the department 130 times for each employee instead of 10 unique departments.
View 11 Replies
View Related