Combobox Based On Previous Combobox

Jan 25, 2006

I've tried searching the forums and haven't found quite what i'm looking for. I would like to be able to change the source for a combobox based on another combobox. The simplest way i can summarize that is i want to be able to choose A or B, depending on my choice i want another combobox to display all the values that A or B can have.

Thanks

Jim

I'm not sure I worded that very well. :(

View Replies


ADVERTISEMENT

Forms :: Update Row-source Of Combobox Based On Value Selected On Another ComboBox?

Apr 26, 2015

I am trying to use a combobox called Manufacturer to select which table the combobox called Model gets it's rowsource from using the code below.

Code:

Private Sub Manufacturer_AfterUpdate()
If (Me.Manufacturer.Value = "Siemens") Then
Me.Model.RowSourceType = "Table/Query"
Me.Model.Recordset = "SeimensTable"
Me.Model.RowSource = "SELECT Model FROM SeimensTable"
Else
If (Me.Manufacturer.Value = "Samsung") Then
Me.Model.RowSourceType = "Table/Query"
Me.Model.Recordset = "SamsungTable"
Me.Model.RowSource = "SELECT Model FROM SamsungTable"
End If
End If
End Sub

But when I run the form and select Manufacturer. Combobox Model remains empty. tell me what I'm doing wrong?

View 5 Replies View Related

How Can I Filter One Combobox Based On Another Combobox Selection?

Apr 22, 2005

I have 2 comboboxes, the first one is called "activity", whereby I have 3 options to choose from, and the second is called "level".

When I click an "activity", for example Drawings, I want the "level" combobox to list a unique set of options for that category. and if I click on a different "activity" for example Planning, I want the "level" combobox to show a completely different set of options.

If anyone can give me any help on how to do this then I would be very grateful!!

Thanks

Angela :eek:

View 2 Replies View Related

Forms :: Copy Record From Previous Field If No Specific Combobox Value

Oct 30, 2013

I have an access form that needs filling in daily by various people.

It's to document changes to a website and I currently have a combobox box set up for the various sections to state whether they are AMENDS, REVERTS or NO CHANGE.

I have set conditional formatting to then highlight these sections but am also trying to get it to work so that if the user chooses "NO CHANGE" then the data for that field copies over from the previous record.

I have set this up in the AfterUpdate code for the combobox, but nothing is happening, not even an error....

Code:
Private Sub COMBOBOX1_AfterUpdate()
If Me.COMBOBOX1 = 3 Then
Me.[FIELD_TO_CHANGE] = DLookup("[FIELD_TO_CHANGE]", "tb_TABLE", "[ID]=Forms![form_FORM]![ID]-1")
End If
End Sub

(Where 3 is the value of NO CHANGE in the combobox, and FIELD_TO_CHANGE, tb_TABLE and form_FORM being the names of the various elements)...

View 1 Replies View Related

Saving Contents Of Combobox As String, And Inputing In Another Combobox

Jan 13, 2005

How would I modify multiple comboboxes in subforms at the same time. For example.. In main form ComboboxA user selects 1992, Combobox1 in subform1 is also changed to 1992, as well as Combobox2 in subform 2.

Whats the best way to do this?

View 2 Replies View Related

Update ComboBox Based On Another

Jun 8, 2006

I currently have a table with two important fields (lets call them X and Y) currently I have them set to ComboBox where they reference two look up tables. I then have a form that allows for user input. Each of the two fields work with drop down lists. What I want to to is filter the Y Field based on the selection in Field X.

I wrote a query that is set to the Second combo box. WHen the user selects the drop down it runs the query and uses the value in the first to narrow the selection.
[forms]![DATA_ENTRY]![HOUSE_NUMBER]
THis works great but only for the first go through. After that it seems that I have to have code on one of the events. Basically any time the user hits the drop down I want to requery.

Does anyone have any code examples that I can reference that will show me how to repopulate that second combobox based on the selection from the first combobox? EVERY TIME I CLICK THE SECOND DROP DOWN BOX ....I would imagine that I have write the code on one of its events...

Does that make sense?

Any help would be greatly appreciated.

Thanks in Advance

View 2 Replies View Related

Combobox Depends On Input Of Other Combobox

Feb 25, 2008

Hey all,

I've read some tutorials on this sort of thing, but I can't seem to piece it all together to achieve what I want.

I have a table Products that contains the fields Product, Size and Brand. I also have a form, frmProducts, that has a combobox linked to each of the fields in the Products table. I want to be able to select a product from the first combobox, tab to the Brand combobox and have only those brands associated with the product already selected.

This is how I think it should work:
1.ComboBox1 selects productA
2.ComboBox2 takes its options from a query that searches Products table for all instances of productA and displays all available brands. brandA is selected.
3.ComboBox3 get its options from another query that searches for all instances of productA that also have brandA and displays all available sizes.

What I'm having trouble with in particular is passing the data between queries. For example, I can't figure out how to tell the query to search for all instances of productA when its defined by the first combobox. Do I have to store it as a variable somewhere?

I hope I've been clear.

View 6 Replies View Related

SubForm Filter Based On A ComboBox

Aug 18, 2006

I am running into a problem with just one form in my database. I was getting the error 'Can't build a link between unbound forms'. After searching here and elsewhere the solution is/might be to type the linked fields into the child and master proprty fields. However when I do that I still can't get this form to work. Would anybody please take a look at the file attached - I trimmed it down to two tables with a few records and a form/subform.

I want to make a selection in the combo box and have the filtered results displayed on the form below - simple and I have done the same thing in the database elsewhere but I just can't see why it won't work here.

Thanks

Steve

View 3 Replies View Related

List Data In Subfrom Based On Combobox

Oct 26, 2005

i just to know how to list the all data at subform that same thing that i selected at combobox..

ok for example..

i want to list all car part that purchased in nov 2005 at subform...
date(nov 2005) selected from combo box...
then if i change other date (ex: dec 2005) it update n view new parts..

is there need some coding at macros?

plz help me im new with access... :confused:

View 2 Replies View Related

Forms :: Retrieve Records Based On Combobox

Jun 25, 2013

I have two Tables, "staff data" (staffID, name) and "issues log" (IssueID, StaffID, 20+ fields about individual Issues). StaffIDs are linked together so each employee can have multiple issues..I have (so far) Form1 containing individual Issues that can be filled in, or retrieved one at a time / scrolled through in IssueID order

What I want is a second form, containing a combobox with all StaffIDs (+ names) listed; when a StaffID is selected, a table is loaded containing all Issues for that employee. When any of these is selected, Form1 is loaded

I have created the second form, including the combo that contains both StaffIDs and Names. I can't yet grasp how to show the set of Issues applicable to that employee when I change that combo...If I could have the combo on Form.

View 2 Replies View Related

Forms :: Go To Record Based On Combobox Selection?

Jan 13, 2015

it's easy to set up a form with a combobox that will list all records and moves the user to the selected record. But I can't figure out how to just show a selection of the records in this combobox, instead of all records.

So, to use the example used in most online tutorials: a drop down menu shows you all the names in a customer database. However, I'd like to have instead a dropdown menu with an overview of all surnames in the database and that I move to the first record with the selected surname.

View 1 Replies View Related

Queries :: Criteria Based On Combobox From Another Table

Nov 25, 2014

How to get my query to run from criteria based on a combobox from another table. I have a field "prac" that has entries such as JF, MG, PM, RJ etc.

My query has the criteria for prac as [Forms]![PracReportPrint]![PracChoice].

PracChoice is the name of the combobox.

If I specify a valuelist for the combobox the query works. I created a different table just for a list of practitioners that contains only an index key and practitioners (JF, MG, PM, RJ, and so forth). When I set the combobox to table/query and select practitioners from my other table I get the correct list,b ut the query doesn't seem to detect what is selected from the combobox.

View 2 Replies View Related

Forms :: Filter Combobox Based On Last End Point

Mar 21, 2013

I have a table which has a "Start" and "End" fields, and i made a query based on this fields which continues to look up the next points until the last end points. I wanted to filter the last end points on the query table that was related on the combobox value.

View 3 Replies View Related

Filtering A ComboBox List Based On A Table Value?

Nov 12, 2014

My database is centered on a main form where users select pieces of information from ComboBoxes (primarily) and submit.

The first part of the form, they must choose from a list of our clients, which is a table with with roughly 5000 rows.

Later on in the form, they must choose a contact person from that client. While Client's may have several contact names (which need to be stored in a table), only one name is necessary for the form portion.

How can I make this Contact Person ComboBox only load names attached to the specific Client selected above?

As it stands right now, the Client List has its own table (along with additional information), and Contact Name is a separate Table with a look up field of Client List.

View 1 Replies View Related

Query For A Month Range Based On Combobox Entry

Aug 2, 2005

Hi,

I currently have a form that creates a report based on a query that takes in a start date and an end date.
What I would like to do is to create comboboxes that will let the user choose a month and year for the report.
Is there a simple way to choose an entire month in access? I've tried using the Month() function to no avail.

The SQL statement for where I select the start and end date is below:

WHERE ((([tblData].[EntryDate])
Between [Forms]![frmByRange]![BeginningDate] And [Forms]![frmByRange]![EndingDate])

Any help would be much appreciated!

View 2 Replies View Related

Autofilling Textboxes With Table Data Based On A Combobox.

Nov 17, 2006

I am creating an Access program for logging in Parcels that are delivered and I am having some problems.

I have a Table called 'Contacts' and within this there are 4 Columns: 'Names', 'Departments', 'Extensions' and 'Emails'.

I also have a Form and there is 1 Combobox and 3 Textboxes relating to this Table: 'Addressed To', 'Department', 'Ext Number' & 'Email'. (see http://c0ld.homeip.net/parcel_log.jpg for details).

What I would like to do is select the Name from the Combobox (Addressed To) and the have the other Textboxes (Department, Ext Number & Email) get auto-filled with the corresponding data that’s within the Table for that Name.

If anyone would like the .mdb for this, please PM me.

Thanks for your help in advance.
Ross Hurrell

View 7 Replies View Related

Filled Text Boxes Based On Combobox Choice

Oct 20, 2005

Hi
I have been searching this forum for 3 hours for a solution, some come close others are pure gobble de gook to me.
I have on a form 1 combobox where a name is chosen, from that choice I would like the address, suburb, state etc automatically placed intheir relevant fields.
I have tried =DLookUp("[PropertyAddress]","tblProperty","[Property]") in the address textbox which will only bring up the first recod's address from the table, if I change the name in the combobox the address doesn't change.
What am I doing wrong, I have designing databases in Access for a total of 7 days now and have been going fairly well with some tips and code snippets from this forum but this has got me stumped.

Cheers
optidisk

View 2 Replies View Related

Subform Based On Selection Combobox In Main Form

Aug 25, 2005

Hello.
I am trying to make an invoice sheet in Access 2000.
My program consists a Order Sheet (frmOrder2), Delivery (frmDelivery) Sheet and a Invoice Sheet (frmInvoice).
All three are linked by DoNo.
The DoNo is made by frmOrder2.

I have a form that is called frmInvoice and a subform called subInvoice.

What I basically want to do is, to get the subform (subInvoice) to show records depending on the selection in the combobox DoNo in the main form.

subInvoice should show the Items, UnitPrice, Amount, TotalPrice, Remarks. These Items should show the records of frmOrder2.

I am kind of confused and totally lost, because I have no clue how to start!
And I am quite a beginner so, bear with me! Thank you!

View 4 Replies View Related

General :: Hide / Show Columns Based On Combobox

Jan 28, 2014

I would like to know if the following is possible: I have a table, I have a form based on that table (datasheet view) and I would like for certain columns to visible or not based on the input on a Combobox (list of countries) that is based on another form.

I have searched on the web and I found that the following:

On a button based on the main menu form:

Code:
Private Sub Go_Click()
Dim stDocName As String
Dim stOpen As String
stOpen = Me!cboDest
stDocName = "Datasheet"
DoCmd.OpenForm stDocName, , , , , , stOpen

and then on the event "on open" of the form Datasheet I have inserted the following:

Code:
Private Sub Form_Open(Cancel As Integer)
Select Case OpenArgs
Case "USA"
Forms![Overflow]![Tasks].Visible = True
Forms![Overflow]![Constant Number (Min)].Visible = True

[Code] ....

I have done it as a test, but it appears that it does not work. It opens the forms, but it does not hide or show the columns based on the option, it brings all the columns.

View 14 Replies View Related

Forms :: Display TextBox Value Based On Combobox Selections

Jun 5, 2015

I have a form that has 3 combo boxes and a text box that I want to be a lookup. I have a little experience with DLookUp, but I do not think that will work here. The three combo boxes are linked to queries, and Tables. The first combo box is for choosing "Precious" or "Base" metals. The second combo box is filtered from the first and displays the "Metal Names". The third combo box is to choose a "Metal Market". There are currently four options for that. I want the text box to display the "Metal Market Price" based on the second and third combo box selections.

Here is a screenshot of the table with all of the metals and their market prices filled in with dummy values for now:

metals screenshot 1.PNG
Metals screenshot 2.PNG

Here is a screenshot of the relevant Form: Metals form screenshot.PNG

Here is a screenshot of the Table that relates to the relevant form: Metals table design.PNG

Here is a screenshot of the Metal Market table that the Query is based on: Metal Market Table.PNG

View 14 Replies View Related

Queries :: Dynamic Query Based On A Form (ComboBox)

Jan 22, 2014

We have a ComboBox on a form with the months: Jan, Feb, Mar, Apr, etc.

We have fields in a budget table named: Jan, Feb, Mar, Apr, etc.

We want to create a query that pulls the correct field based on the value in the combo box.

This is what I have that doesn't work:

MyField: [Query1].[SumOf] & Forms![Main Menu]![test]

How to do this?

View 4 Replies View Related

Forms :: Hide And Show Controls Based On Value In Combobox

Apr 22, 2014

I am using Access 2010. I wish to show or hide controls based on the value in the combobox. The combobox is bound with the data type Yes/No. If Yes, controls should be visible and if no, they are to be invisible. The database is a linked one. This selection should update all the users' forms.

View 2 Replies View Related

Forms :: Combo Box Values Based On Selection On Another Combobox

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

Forms :: Open Form Based On Combobox Selection

Feb 12, 2014

I have three different forms.

1. form is a Login form where i choose between: AA, HH or FA

After choosing on my first form second form opens.

Now my question - how can i do the following:

Based on the combobox in form 1, my button i form 2 will either open form 3, 4 or 5...

View 1 Replies View Related

General :: Populating Field Based On Combobox Selection?

Oct 29, 2013

I have a table of raw materials that have two fields, their stock code and longer description.

I have another table that is tracking the usage of these materials. I want both the stock code and longer description to be recorded in the usage table.

I want the "Description" field in the usage table form to auto populate when the user selects the corresponding stockcode from a combobox.

View 3 Replies View Related

Forms :: Passing Multiple Values Based On ComboBox

Jul 10, 2014

I have a form where the user will choose a contact name or names from a multivalue combobox and I want the email address field to update with the corresponding emails separated by "; ".

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved