Re: Cascading Combo help
- From: "Dirk Goldgar" <dg@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Thu, 25 Sep 2008 15:20:04 -0400
"Tara" <Tara@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message news:4291722F-4481-410F-AF86-C71A1AC1DAEF@xxxxxxxxxxxxxxxx
I have two combos on a frmEmployees. 1st combo is cboCity, 2nd is cboZip.
Both are based on the same table. I'm trying to get the second combo to be
limited based on what is chosen in the first combo, but it doesn't appear
that the After Update Event is firing at all. That or I'm missing something
obvious.
The 1st combo's RowSource is as follows:
SELECT DISTINCT [tblZip].[strCity] FROM tblZip ORDER BY [tblZip].[strCity];
The 2nd Combo's RowSource is:
SELECT [tblZip].[numZip], [tblZip].[strCity] FROM tblZip WHERE
((([tblZip].[strCity])=[forms]![frmEmployee]![City]));
In the After Update event of the 1st combo I have:
Me.cboZip.Requery
I've also tried using DoCmd.Requery "cboZip"
Interestingly, if I run the query behind cboZip independently of the After
Update Event, it works fine!
What am I missing here???
I trust that the first combo box is either named "City" or is bound to the [City] field.
Maybe the AfterUpdate event is not firing. Is the AfterUpdate event property of the combo box set to "[Event Procedure]"? If you put a breakpoint in the event procedure, does execution hit that breakpoint when you choose a value in the combo box?
Does other VBA code in the database execute? This isn't Access 2007 with VBA code disabled, is it?
--
Dirk Goldgar, MS Access MVP
www.datagnostics.com
(please reply to the newsgroup)
.
- Follow-Ups:
- Re: Cascading Combo help
- From: Tara
- Re: Cascading Combo help
- References:
- Cascading Combo help
- From: Tara
- Cascading Combo help
- Prev by Date: Re: higher of two values
- Next by Date: Save reord from a form
- Previous by thread: Cascading Combo help
- Next by thread: Re: Cascading Combo help
- Index(es):
Relevant Pages
|