Can't Get A Combobox To Show The Value I Want

Apr 23, 2006

i searched for similar combobox features, nut didn't find any that helped.

i have 2 unbound combos that get heir values from different tables

first combo1 gets its values from a query
SELECT [tbl_music].[MID], [tbl_music].[Artist], [tbl_music].[Song], [tbl_music].[CID] FROM tbl_music;

combo2 gets values from
SELECT [tbl_category].[CID], [tbl_category].[Category] FROM tbl_category;

IDs are autonumber and primary
The CID fields in the tables are in a 1..* relationship

Both are constructed with the wizard and the ID columns are hidden.

What i need is:
when selecting something from combo1, the combo 2 should show the right category for that song.

Hope i explained clearly enough.
I tried to use the dlookup function, but i get error 94, invalid use of null.
i'm using the afterupdate event.

I can update a textbox text, but can't do so with the combobox value.

Any ideas what i'm donig wrong :confused: :confused: :confused:

View Replies


ADVERTISEMENT

Show All Data Off A Combobox On A Subform

Aug 19, 2006

I have a subform for a hotel list, I have a combobox on the subform that show the list of the hotels, what I need is to create some fields on the subform wich shows me all the details of the hotel as address, email, facilities once I have selected a hotel from the combo list.
How can I achieve this!
Thanks
Marco

View 7 Replies View Related

Forms :: How To Show Image In ComboBox

Jan 4, 2014

I have a question about combo box , i want when i click on combo box show picture , for example i create a form by 2 languages (English,French) each language have a specific flag , when i click on the combo box show English and beside English show USA flag with French Language and beside French show flag of French.

View 3 Replies View Related

Using Combobox To Show Only Remaining Items?

Sep 18, 2015

I want to use combo box to select the resources to assign, but want to only show the remaining item, each time I click for new record.for example staff allocated for different jobs.

seat assigned to each person, so each time the free seats only be displayed in the list, Not the already assigned.

View 2 Replies View Related

Combobox Selections Show In Memo Field

Jan 17, 2005

Is there a way to show all combobox selections in a memo field so the user knows what they have already selected? Thanks for any help.

View 2 Replies View Related

Combobox To Show Only Last ID In List When Form Loads

Mar 4, 2015

How I can get a combo box to show only the last id in its list when the form loads.

View 1 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

General :: Combobox Filtering Listbox To Only Show Same Records

Apr 4, 2013

Ok I have a list box (CounselorInitials) and a listbox (AssignedToYou)

The list box has 6 columns and is using a query (AssignedToMe). The important one is the 6th one (Counselor). All working off a table called DityLog.

I want to select initials in the combo box and then it will filter the listbox and only show records that are the same.

So if I select initials MC from the combo box I want the Listbox to show all records that have the initals with MC.

View 1 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

Queries :: Select Distinct For Combobox - Show Only Unique Values

Oct 20, 2014

I am trying to get a combo box to only show unique values, but I can't get it to work properly - it still shows duplicates in the list.

The Row Source is set to

SELECT DISTINCT Areas.ID, Areas.Area FROM Areas ORDER BY Areas.Area;

And the combo is bound to column 2

View 12 Replies View Related

Modules & VBA :: Show The First Primary Key Field In The Combobox When The Form Loads?

Aug 30, 2013

I'm using a combobox to select a record based off my primary key field, and then a separate button to print that particular record.

When the form loads, it has the first record selected but the combobox is empty so that if I press my button it will still print the first record.

when I press the combobox my list of entrys in the primary key field shows up and the combobox is no longer blank.

How do I show the first primary key field in the combobox when the form loads?

View 6 Replies View Related

General :: Lookup Combobox - Field Show Number Instead Of Text In Listbox

Jul 7, 2014

I have a field in a table where it is a lookup is a combo box. So this makes the data type of the field a number when in reality it is a text. When I have this field show in a list box it shows the number instead of the text.

View 5 Replies View Related

Show Current Record Value From Table In Combobox In Addition To Query Results

May 3, 2015

I have a table, with a related value in another table. E.g. A Items table with a batch value from another table.

I have a form to enter how many of these items has been used and from which batch number they belong.

The batch number is from a dropdown, and batches can be finished(exhausted) and marked such in the table so they no more show in the dropdown.

All this works fine, until, I go back to a entry which was from a batch that has been finished. The combobox is empty although the (Already finished) batch number is mentioned in the table. This is perfectly normal as my query for the combobox is :

Code:

SELECT ItemBatch.ItemId, ItemBatch.ItemBatchNumber, ItemBatch.Finished, ItemBatch.ItemName
FROM ItemBatch
WHERE (((ItemBatch.Finished)=False)
AND ((ItemBatch.ItemName)=[Forms]![ItemMasterForm]![ItemDataSheet].[Form]![ItemName]));

What I want is to show the current batch number as well. I tried to make this query get the current value, but wasn't successful. I tried to make a calculated field based on the dropdown and show its value.

Is there any way I can show the batch number in the datasheet? I have to use a datasheet and not a form, because there will be many sub records for the main form, and having a form will be very uneasy.

View 3 Replies View Related

Forms :: How To Link Combobox Between Form And Subform To Only Show Selected Filtered Data

Apr 1, 2013

I have a suppliers table and a products table. Two forms, Stock form with combobox to list Suppliers and a sub form with combobox that lists Products.I want to select a supplier from the Stock form and then the combobox in the subform to only list products directly sold by the Supplier.Have dabbled in SQL as follows:

SELECT Products.ProductID, Products.ProductName
FROM Suppliers INNER JOIN Products ON Suppliers.SupplierID = Products.SupplierID
WHERE ((Stocksubform.SupplierID=Stock.SupplierID))
ORDER BY Products.ProductName;

View 2 Replies View Related

Forms :: Combobox On Navigation Form Header - Query Table To Show Right Info

Mar 24, 2013

I created a navigation form on which I put a form call [frmAnimal Setup].

I then placed one combo box on the Navigation frm Header. I have bound it to its source and it actually queries the tbl and show the right info. However when I select one, it will not let me.

In addition, [frmanimal setup] will not allow me to select a breed although it does query the tbl and shows the right information.

View 1 Replies View Related

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

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

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

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 1 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

User Defined Show/No Show Query Results

Jul 5, 2005

I have a parameter query built and am curious if anyone knows of a good way to allow the user to define which fields are displayed in the query results.

i tried looking for other threads discussing this without any luck.. not sure if it was my search terms or what. thanks so much for any help..

View 10 Replies View Related

How Do I Show Convert Vertical Entries To Show Horizontally

Jun 7, 2007

Is it possible to convert fields listed down to show across.

IDNo Code Position
AAA B01 1
AAA C01 2
AAA D01 3
AAA E01 4

I want to show it as
IDNo Code Code Code Code
AAA B01 C01 D01 E01

Is this possible using Access 2003?

View 7 Replies View Related

Query To Show Show Different Results From Same Group

Jun 11, 2006

I wondered if someone could help.

I have 3 columns of data within a table and from a select query am trying to seperate certain groups.

Table 1

yr period valuehome

2006 0 100
2006 0 10
2006 1 1000
2006 1 800
2006 2 60
2006 2 50
2006 3 40
2006 3 10
2006 3 5
2006 3 70
2006 4 50
2006 4 5

I wish to show both results for period 0 and an accumulative total for periods 1-4

so results would be

year period Total sum

2006 0 110
2006 1-4 2090

Can anyone help?

thanks

Paul

View 5 Replies View Related

Reports :: Show Detail - Using Section Header As Hyperlink To Show / Hide Detail

Aug 13, 2013

I'm trying to create a report where I can use a section header as a hyperlink to show/hide detail, but only for that section. For example, my customer names are:

Code:
ABC Co.
ZYX Co.
123 Co.

If I click on ZYX Co., I want it to show the contracts for ONLY that customer:

Code:
ABC Co.
ZYX Co.
Contract 1
Contract 2
123 Co.

Right now, my code looks like this for On_Click:

Code:
If Me.Detail.Visible = False Then
Me.Detail.Visible = True
Else
Me.Detail.Visible = False
End If

But it shows and hides detail for ALL customers when I do this. Is there a way to only show/hide for the customer on which I click?

View 1 Replies View Related

Show/not Show Control

Mar 14, 2006

how can i control a field to show/not show at the query level?
let's say i have a query (from a table) like this

[regularPrice] [isOnSale] [onSalePrice]

where [isOnSale] is checkbox. if it's checked, [onSalePrice] will show [price]*0.9; if it's not checked, [onSalePrice] show nothing.

i've tried to put "[isOnSale]=Yes" in the Criteria, the query will filter out only those records that's on sale, which i don't want...

please help :confused:

View 2 Replies View Related

ComboBox ??????

Jun 6, 2005

If I want the combo box to read entry's from one table and then store in another table how would this be done? I think it has to be done with the query builder but I am not sure. I am sorta new to Access.

View 2 Replies View Related







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