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  

Continuous Forms from Cascading Combo Boxes



 
 
Thread Tools Display Modes
  #1  
Old October 27th, 2009, 01:48 PM posted to microsoft.public.access.forms
Esmerelda
external usenet poster
 
Posts: 2
Default Continuous Forms from Cascading Combo Boxes

I have a form with 2 cascading combo boxes in the form header. The first is
to select the year & the next to select the version.

The source of the Year & Version is the same query from which I need the
data to be shown in the detail section of the form

TSL Number
ABC 5000
BCD 3000
Etc

I have a query ‘Data Query’. It has the fields: Year, Version, TSL, Value
Eg

Year Version TSL Value
2008 1 ABC 99
2008 1 BCD 50
2008 2 ABC 75
2008 2 BCD 60
2009 1 ABC 87
2009 1 BCD 45
etc

I want to set up a continuous form with 2 Cascading combo boxes (I’m OK with
the cascading bit) from which I can select Year & Version, & then have the
corresponding TSL & Value list show in the Detail area.

I know I need to set requery’s on the ‘Onload’ & ‘AfterUpdate’ events for
the appropriate boxes, but I can’t even get the form to only show the data I
want at the moment.

In the text boxes in the Detail section, what do I need to use as the
control source?

I’ve seen the posts where it says to add the data to the Combo boxes & then
use field 2 etc, but if I do that, instead of a nice 2008, 2009 list, I get
them repeated several hundred times.

Thanks


  #2  
Old October 27th, 2009, 02:57 PM posted to microsoft.public.access.forms
Arvin Meyer [MVP][_2_]
external usenet poster
 
Posts: 2,310
Default Continuous Forms from Cascading Combo Boxes

Have a look at the cascading list boxes at:

http://www.accessmvp.com/Arvin/Combo.zip

You need to use the same type of thinking in your queries, so that the
subform recordsource is based on the query which produces the result you are
looking for.
--
Arvin Meyer, MCP, MVP
http://www.datastrat.com
http://www.mvps.org/access
http://www.accessmvp.com


"Esmerelda" wrote in message
...
I have a form with 2 cascading combo boxes in the form header. The first is
to select the year & the next to select the version.

The source of the Year & Version is the same query from which I need the
data to be shown in the detail section of the form

TSL Number
ABC 5000
BCD 3000
Etc

I have a query 'Data Query'. It has the fields: Year, Version, TSL, Value
Eg

Year Version TSL Value
2008 1 ABC 99
2008 1 BCD 50
2008 2 ABC 75
2008 2 BCD 60
2009 1 ABC 87
2009 1 BCD 45
etc

I want to set up a continuous form with 2 Cascading combo boxes (I'm OK
with
the cascading bit) from which I can select Year & Version, & then have the
corresponding TSL & Value list show in the Detail area.

I know I need to set requery's on the 'Onload' & 'AfterUpdate' events for
the appropriate boxes, but I can't even get the form to only show the data
I
want at the moment.

In the text boxes in the Detail section, what do I need to use as the
control source?

I've seen the posts where it says to add the data to the Combo boxes &
then
use field 2 etc, but if I do that, instead of a nice 2008, 2009 list, I
get
them repeated several hundred times.

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 11: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.