A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Form selection based on previous



 
 
Thread Tools Display Modes
  #11  
Old August 28th, 2006, 02:04 PM posted to microsoft.public.access.forms
Klatuu
external usenet poster
 
Posts: 7,074
Default Form selection based on previous

Post what you have the the row source in both combos, please.

"Paul Shellien" wrote:

Klatuu

Bet you thought i had disappeared. Sorry, but like the proverbial bad
penny, I just keep turning up.

I tried putting in those sql lines you gave, but just end up with blank combos

Heres what i got again


Manufacturer

MfrID - Autonumber
Mfr - the name of the manufacturer

Model

ModelID - Autonumber
Model - text
MfrID - I have populated this field by using a select box from the
Manufacturer table that puts in the MfrID and Mfr. MfrID is hiddden so only
the name can be seen.
Price - cost for each unit(will use this later on to populate another filed
depending upon which model is selected.

Am i going horribly wrong soomewhere? or am i being a dimmer than a 5W lamp
that is on half power. Feel like I am getting nowhere and am being a pest

Sorry for the bother again, but am at wits end with this as 1-it is beating
me and i dont like that and 2-Mrs S is getting on my ase to have this up and
running

Cheersin advance

Paul


  #12  
Old August 29th, 2006, 07:57 AM posted to microsoft.public.access.forms
Paul Shellien
external usenet poster
 
Posts: 5
Default Form selection based on previous



"Klatuu" wrote:

Post what you have the the row source in both combos, please.

Klatuu

Row sources as follows

For Manufacturer Combo - tbl.manufacturer
For Model - tbl.Model

Thanks
  #13  
Old August 29th, 2006, 01:55 PM posted to microsoft.public.access.forms
Klatuu
external usenet poster
 
Posts: 7,074
Default Form selection based on previous

Sorry, Paul, I am still not getting enough info to really help.
My original reply showed how you use one combo to filter what is presented
in the second combo. I don't really understand the difficulty here.
Let me restate how it operates.

The usual way to set up your tables is, as you already have, a table for the
manufacturers. In most cases, there will be a code that identifies the
manufacturer to the computer. That code, however, is probably not something
a human can quickly understand. So, to make it easy for both, you would use
a 2 column combo. The bound column would be the code. It is usually Column
1; however, when addressing that column in VBA it is known as Column(0). The
second column - Column(1) - would be the name. If you don't want the user to
see the code column, set its column width to 0.

The second combo is based on the model table. It also needs a code and a
description and is set up the same as the previous combo. Then when the user
selects a manufacturer in the first combo, the After Update event fires.
That is where you requery the model combo so it will only show the models for
the selected manufacturer. That is done by setting up the query to filter on
the value in the manufacturer combo. It would look something like this:

SELECT ModelID, ModelDescription FROM tblModels WHERE mfgID = Me.cboMfgr;

The mfgID would be a field in the Model table. It will be the same value
for every model that belongs to that manufacturer and is the code in the
manufacturer table that identifies the manufacturer.

"Paul Shellien" wrote:



"Klatuu" wrote:

Post what you have the the row source in both combos, please.

Klatuu

Row sources as follows

For Manufacturer Combo - tbl.manufacturer
For Model - tbl.Model

Thanks

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 04:45 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.