I know that this has been addressed before, but for the life of me, I cannot get it to work!
I am building and DB to record scores for a sporting club. We have a match each week, but the actual discipline is different, and so is the scoring system. I have a table (tblMatches) that contains the date, the discipline and comments. I then have different tables to record scores for each discipline (tblActionScores, tblServiceScores etc.)
I have a form that will be used to enter scores. The main form contains the fields for the tblMatches data. I want a subform that will change, depending on what MatchType is selected (frmActionScores when the combo box is "Action Metallic" for example.)
I have the following code under the AfterUpdate event on the combobox:
UG added code tags
I just can't get the subform to actually change!
Thanks for any help
Matt
I am building and DB to record scores for a sporting club. We have a match each week, but the actual discipline is different, and so is the scoring system. I have a table (tblMatches) that contains the date, the discipline and comments. I then have different tables to record scores for each discipline (tblActionScores, tblServiceScores etc.)
I have a form that will be used to enter scores. The main form contains the fields for the tblMatches data. I want a subform that will change, depending on what MatchType is selected (frmActionScores when the combo box is "Action Metallic" for example.)
I have the following code under the AfterUpdate event on the combobox:
UG added code tags
Code:
Private Sub MatchType_AfterUpdate()
Select Case Me.MatchType
Case "Service"
Me.subfrmScores.SourceObject = "frmServiceScores"
Case "[Action Metallic]"
Me.subfrmScores.SourceObject = "frmActionScores"
End Select
End Sub
I just can't get the subform to actually change!
Thanks for any help
Matt
Last edited: