Change Combo Contents Based On Previous Combo Selection

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 Replies


ADVERTISEMENT

Forms :: Image Change Based On Combo Box Selection On Form

Jun 21, 2015

I have been looking some information on changing image based on form combo box selection on form.

I manage to do case by case but i need it in a simple code because their will be many employees just to avoid adding case by case code for each one.

Private Sub Emp_IDCombo_AfterUpdate()
Select Case Emp_IDCombo.Value
Case "AM-001"
Imageholder.Picture = "C:UsersAMGDesktopam-001.jpg"
Case "AM-002"
Imageholder.Picture = "C:UsersAMGOne DocumentsHR & Admin DatabaseEmployee Picturesam-002.jpg"
End Select

I have employees table where all images location is saved in text field and i have a combo box on form which is employee id.

Tables relationship
Employees_table [PK] to Contracts_table [FK] via field name {emp_ID}

Fields Name
Combo Box name on form Emp_IDCombo and row source is SELECT Employees_table.Emp_ID, Employees_table.EmployeeName, Employees_table.Emp_Pics FROM Employees_table;

Text field is located in employees_table called [Emp_Pic] for images location.

View 10 Replies View Related

Change Value In Query From Command Button Based On Selection In Combo Box?

Jun 3, 2015

I have a dashboard-style form that has a list box with tasks connected to a query with line items of those tasks.

I have another query that will only show the line item selected from the list box. This means the query will only have one line item.

I want to have a command button below the list box that, when clicked, will modify the solo item in the second query to change a yes/no field from no to yes.

How can I accomplish this? Also, how can I make a button that deletes the selected line item?

View 3 Replies View Related

Populate Combo Box Based On Selection In Another Combo Box (Access 2010)

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

Forms :: Change Record Source Of Combo Box On Form Based On Another Combo Box

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

Forms :: Combo Box Value Based On Selection In Other Combo Box?

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

Combo Box Values Based On Another Combo Box Selection

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

Enabeling Seccond Combo Based On Previous

Oct 13, 2006

Hello!
I have honestly spent the better part of the past two days searching this forum and trying (but failing) to find a solution to my problem.

I know that my question has been asked many times, and several possible solutions have been given... however, none of them work for me:-( Oh, by the way, I just started using Access (2003) this Monday, so please IF there are anyone that can offer assistance, please do so in silly detail...

I have a form with several combos. One combo I would like to enable only if one specific choice is selcted in the previous combo. The solution given to many before me is to enter the following in the After_Update field of the first Combo:

Private Sub Source_AfterUpdate()
If Source = "Contracted Operator/Agent" Then
AgentOperator.enabled = True
Else
AgentOperator.enabled = False
End If
End Sub

After I have done this, the AgentOperator combo does become disabled, but it is also disabled when "Contracted Operator/Agent" is chosen in the Source Combo. I thought the code was supposed to leave the "Contracted Operator/Agent" enabled??? Why is it not doing this? Why is it disabling with all choices?

I would be really grateful if someone can be kind enough to help me. I feel so stupid not being able to handle this one on my own. It really is hard to over the years have become somewhat of an Excel professional, but now I am a complete novice....

Thank you so much in advance!!!

View 9 Replies View Related

Querying Based On Combo Selection

Jan 27, 2006

Right, I think this is a quick and easy one....just not for me!

I have a combo box with a list of names. I want to use whichever name a user selects as criteria for a query.

What do I need to type in the query criteria box or as SQL?

View 2 Replies View Related

Textbox Based On Combo Selection

Jan 19, 2006

I choose a ‘Year’ from a combo box. Why doesn’t the data in my textbox update? (It’s a count of records for that year)

View 2 Replies View Related

General :: Based On Combo Box One Selection

Jul 29, 2012

if it is possible whereby if a user makes a selection in combobox 1 it must automatically generate the given vaules in combobox2 from the selection in combobox 1.

View 1 Replies View Related

Combo Box Event Based On Selection

Oct 18, 2011

I know how to assign an event to a combo box, but I want to be able to launch a specific link, app, or email template, based on the actual selection from the combo box. So when I make a selection, whatever program or event I assign, to that specific selection, will launch.

View 14 Replies View Related

Refresh Subform Based On Combo Box Selection

Dec 30, 2005

I have a form with three subforms, and I'm having problem with one of them. The link between subforms and forms are store number, which is stored in a combo box. Idealy, after a user pick a store from the combo box, the subform would update itself. Two out of the three subforms are based on two crosstab queries and they work perfectly fine. The last subform is a select query, and it seems like it's not rerunning itself after updating the combo box. The query is very simple, it just has store number, description, and grouped by amount. I tried with no criteria in the store field and run the masterform,seems like all it's doing is showing value for the first store in the table, and never changes afterwards, I also tried entering "forms!frmStores!cmbStore" in the criteria for the store, then the subform came out empty, it seems like it's only reading combo box's default value null. I have a line of code for the mater form frmStores as "me.[DisplaySubform].requery" for all three subforms, but it seems like it's working for the first two and not the select query. Anybody can help me with this? oh, the combo box is unbounded, because i do not want my table to be updated by selection. Please help

View 1 Replies View Related

Print Form Based On Combo Selection?

Apr 10, 2006

Hello!

I have almost completed my database, everything I had originally intended to implement into it has been done, with some extra added features I popped in along the way. There is just one more thing I require assistance with...

My database is used for booking camera kits in and out. On the add booking form the user has to pick a "Camera Type" from a combo box. When they have made their selection, a form pops up with details of all of the components contained within the kits. The user can then check/uncheck the relevant components and close the form.

I have used a command button which prints off the data contained within the current booking form, and also the data contained in the form that pops up when the camera type is selected.

However, as there are more than 1 different types of camera, comprising different components, I need to be able to print off the form relevant to the kit type.

I do not know how I can do this as I have just specified the command button to print the form for the default kit.

I basically need some VB code which will print the form based on my combo selection, as my knowledge of VB is pretty primitive, I was wondering if someone could help me out :)

Any help would be appreciated!

View 2 Replies View Related

Enabling Textboxes Based On Combo Box Selection

Nov 8, 2006

Hi all,

Is there any way of enabling/disabling a number of text boxes/checkboxes, based on a combo box selection, for example:

Combo Box 1: Airport Selection
Combo Box 2: Customer Selection

Once the user has selected the customer, based on the airport selection there will be about 10 text boxes and a few checkboxes that I'd like to allow or "ghost" depending on whether we are contracted to carry out work for that customer.

Any help would be appreciated.

thanks, Graeme

View 2 Replies View Related

Conditional Visability Based On Combo Box Selection

Dec 22, 2006

I'm not new to object oriented programming but I am new to Access. I have found some questions similar to mine in search but I need more explanation if someone wouldn't mind.

In my form, I have a combo box that looks up 3 values from another table. Among other controls, I have a few text boxes that I only want visible if 1 of the 3 possible combo box options are selected.

I understand that the code for this should probably be placed in the "events" of the of the combo box...which one? I understand the logic but what would the code look like? Do I use the expression builder?

Thanks for any help on this.

View 1 Replies View Related

Refreshing A Query Based On A Combo Box Selection

Dec 1, 2004

I have a form on which i make a selection. This selection then populates a query which in turn generates a report. The problem that i have is that when i go back into my form and make another selection the query, and therefore the report, holds the original data.

My question is how can i refresh the selection and therefore produce different reports based on this selection without exiting the application?

Many thanks for any help provided in advance.

View 4 Replies View Related

How To Generate Report Based On Combo Box Selection

Jun 30, 2005

Hi guys . I created a form that has 3 combo boxes. Their name are Project Number, year and weekno . It has also a button that on click action supposed to generate a report baced on my combo box criteria and then loads that report for me. could any expert show me an example on how to do this. I have difficulty finding an example in google since i did not exactly what is called this method of generating report in access 2000.Thanks

View 2 Replies View Related

Queries :: Populating One Combo Box Based On Selection In Another

Jul 20, 2014

I can't quite get my code right for populating one combo box based on the selection in another. I didn't create this Access database but I've been asked to add in a second combo box that is based on the selection of the first combo box.

My first combo box is for Rohe (the location of the Maori tribe) and the second is Iwi (the tribe name). So my first combo box (Rohe) has Dvic_ROHE written in the control source and its row source code is:

SELECT tblLookUpValues.DatabaseFieldValue
FROM tblLookUpValues INNER JOIN tblFormQuestionLookUp ON tblLookUpValues.LookUpID = tblFormQuestionLookUp.LookUpID
WHERE (((tblFormQuestionLookUp.FormID)=2) AND ((tblFormQuestionLookUp.QuestionNumber)=75))
ORDER BY tblLookUpValues.DisplayOrder;

The combo box for Rohe (tribe location) is populated by a table named tblLookUpValues. The second combo box for Iwi (tribe) has Dvic_Iwi in the control source. I created a table named tbl_Rohe_Iwi_lookup that contains ROHE (a list of tribe locations) and IWI (the tribes). There are 12 tribal locations and another 10-14 tribes in each location.
The form that the Rohe and Iwi combo boxes are located on is called frmDeceased. This is the code that I attempted to write so that the second combo box (Iwi) is populated with only the tribes that are in the Rohe (location) that was selected from the Rohe combo box. But when I run the query it comes back with no results.

SELECT distinct tbl_Rohe_Iwi_lookup.Rohe, tbl_Rohe_Iwi_lookup.Iwi
FROM tbl_Rohe_Iwi_lookup
WHERE (((tbl_Rohe_Iwi_lookup.Rohe)=[forms]![frmDeceased]![Dvic_Rohe])) UNION select distinct null, null
FROM tbl_Rohe_Iwi_lookup
ORDER BY tbl_Rohe_Iwi_lookup.Iwi;

View 5 Replies View Related

Reports :: Get A Report Based On A Selection From A Combo Box

Jun 16, 2015

I am trying to get a report based on a selection from a combo box. The issue is many fold. Firstly I have been playing around with it so much that I have messed up the syntax and can't remember what I had. Here is what I have at the moment (this is based on a button):

DoCmd.OpenReport "RepClassrooms", acViewPreview, , " Class = '" & Me.cmboRepClass & "'"

The second issue is that it isn't filtering on the combobox - it gives all the data from the database based on all the entries in the combobox but this is probably down to the syntax again.

View 2 Replies View Related

Forms :: Text Box Based On Combo Box Selection

Dec 31, 2014

I am trying to auto populate the text boxes in the form based on drop down from the combo box. As you can see in the form Frm_Input, this works fine for FL, but for some reason it will not populate for Skill, Role, FLM and Location. The table it is linking to is Tbl_Names. Why as I have changed the column source?

View 8 Replies View Related

Populate Data Based On Selection From Combo Box

May 16, 2013

I have a form that has a combo box in the header. I want to be able to select an employee name and the remaining info in the detail section of the form populate. My other fields are:

Employee Name - text box
Reporting Unit - combo box
Department - combox box
Primary Phone - text box
Secondary Phone - text box
Emergency Contact Name - text box
Relationship - text box
Emergency Contact Primary Phone - text box
Emergency Contact Secondary Phone - text box
B-Alert Txt - combo box
B-Alrt Phone - combo box
e-mail - text box

View 6 Replies View Related

Emailing A Report Based On A Combo Box Selection

Dec 10, 2013

I am using access 2010...and i have a form with a combobox on it...and in that combobox shows a list of employees names. When i currently select the name of the person that i want, it creates their own individual report of their workload.What I want to do is to be able to select that person and it generates their individual report and then attaches it in an email to that individual.

View 9 Replies View Related

More Info Button Based On Combo Box Selection

May 21, 2012

More Info" button based on Combo Box selection. I need to create a command button that can be used to see all of the data in the table for whatever name is selected in a combo box. For example, if John Smith is selected from the combo box, the user could click a "More Info" button, which will open a separate form showing all the data in the table for John Smith.

View 1 Replies View Related

Updating Combo Box Contents Dependant On Other Combo Box

Nov 15, 2004

I have created a database that is used to track various programs that our organisation runs, and keeps a record of which Division the program is in.

at the moment I have a main form which has a combo box that lists Divisions, then I have a subform that has a combo box on it that lists the purchasers.

what I would like to do, is to have the Purchasers list update when a Division is selected in that main form, as depending on which Division is chosen the contents of the Purchasers list changes drastically.

Is anyone able to offer some assistance?

View 1 Replies View Related

Print Specific Report Based On Combo Selection?

Apr 18, 2006

Hi

I need to print a specific form based on the selection made on a combo box.

I have been able to set it up to open the relevant form when the user selects an option from the combo box, but am unable to find a way to be able to print the specific report based on the selection.

I have a command button which prints a report based on the data in my current form, but would like it to also print the specific form based on the combo box selection.

Is this possible, and if so how is it possible?

Thanks in advance,

me

View 5 Replies View Related







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