Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Forms / May 2007

Tip: Looking for answers? Try searching our database.

Using a combo box to see whether companies have certain products

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Daniel - 30 Apr 2007 17:10 GMT
Hi,

I have a form with different combo boxes in the header section.  Based on
the selections made in these boxes, the form is filtered and the results
shown in the detail section as a continuous form.  I want to add another
combo box that shows different product types.  For example, one choice will
be Product1, which will show all companies that make Product1.   The main
thing is that each product has 4 types, but all the user will care about is
whether a company has any of the types.

I'm not too familiar with VB, but I picture the combo box storing variables
that represent each product and whether any type of that product is made.  
(Ex: Product1 in combo box = True If Product1A in table, Product1B in table,
Product1C in table, or Product1D in table equals True.  ELSE Product1 in
combo box = False.

I understand that's not real syntax, but that's how it looks in my head.  
Hopefully this all makes sense.

Thanks!
Hunter57 - 01 May 2007 03:32 GMT
Hi Daniel,

A combo box usually gets its data from a query.  Access Queries are

1. Easier to create in Access than VBA.
2. Incredibly powerful tools when collecting, sorting, displaying, or
calculating data.

A query for the combo box might look something like this:

SELECT DISTINCT tblProducts.ProductID, tblProducts.ProductType,
tblProducts.CompanyID, tblCompanies.CompanyName
FROM tblProducts, tblCompanies
ORDER BY Products

Or

SELECT DISTINCT tblCompanies.ProductID, tblProducts.ProductType,
tblCompanies.CompanyID, tblCompanies.CompanyName
FROM tblProducts, tblCompanies
ORDER BY Products

Hope it helps.
Hunter57
Just huntn' for the right data.
http://churchmanagementsoftware.googlepages.com

> Hi,
>
[quoted text clipped - 16 lines]
>
> Thanks!
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.