I have two combo boxes,divisionCombo and classTypeCombo, on a multi record form named schedules
I am trying (as many other newbies before me have) to have the contents of the classCombo based upon the selection made in divCombo.
Here's my record source for divisionCombo:
SELECT [divisionID], [divisionName] FROM Division ORDER BY [divisionName]
and for classTypeCombo:
SELECT [classTypeID], [classTypeName] FROM classType WHERE [classType].[divisionID]=[Forms]![schedules]![divisionCombo];
Note: divisionID and classTypeID are hidden
and finally here's the code I have for the AfterUpdate event for divisionCombo:
Private Sub divisionCombo_AfterUpdate()
classTypeCombo.Requery
End Sub
Here's my problem: As I move through the records, everything is fine as long as the division does not change. As soon as I change the division the classtype for all different divisions disappears.
Also, if I just click through the classtype fields from record to record (as I imagine a user might) I only see the records for the last division I entered (not necessarily the one selected for the record.
Any help is appreciated! Thanks!
I am trying (as many other newbies before me have) to have the contents of the classCombo based upon the selection made in divCombo.
Here's my record source for divisionCombo:
SELECT [divisionID], [divisionName] FROM Division ORDER BY [divisionName]
and for classTypeCombo:
SELECT [classTypeID], [classTypeName] FROM classType WHERE [classType].[divisionID]=[Forms]![schedules]![divisionCombo];
Note: divisionID and classTypeID are hidden
and finally here's the code I have for the AfterUpdate event for divisionCombo:
Private Sub divisionCombo_AfterUpdate()
classTypeCombo.Requery
End Sub
Here's my problem: As I move through the records, everything is fine as long as the division does not change. As soon as I change the division the classtype for all different divisions disappears.
Also, if I just click through the classtype fields from record to record (as I imagine a user might) I only see the records for the last division I entered (not necessarily the one selected for the record.
Any help is appreciated! Thanks!