G
GeoBrooks
I have a form on which there are two tabs, one for mothers, one for babies.
The babies tab contains a subform in which new records may be added. The
related code snippet is:
Forms!frmmomsbabies!ctlSubBabies.SetFocus
DoCmd.GoToRecord , , acNewRec
Forms!frmmomsbabies!ctlSubBabies.Form!mom_id = intMomId
Forms!frmmomsbabies!ctlSubBabies.Form!txtBaby.SetFocus
This snippet worked, and now doesn't, and I cannot figure out what I might
have done to cause this. [Oh, for a revert to history!] The line where a
control's value is set (Forms!frmmomsbabies!ctlSubBabies.Form!mom_id =
intMomId) is the one that now gives the error "You entered and expression
that has an invalid reference to the property Form/Report." In debugging,
typename(Forms!frmmomsbabies!ctlSubBabies) is SubForm, but appending .Form to
it yields an error.
Any & all clues are more than welcome.
TIA.
George
The babies tab contains a subform in which new records may be added. The
related code snippet is:
Forms!frmmomsbabies!ctlSubBabies.SetFocus
DoCmd.GoToRecord , , acNewRec
Forms!frmmomsbabies!ctlSubBabies.Form!mom_id = intMomId
Forms!frmmomsbabies!ctlSubBabies.Form!txtBaby.SetFocus
This snippet worked, and now doesn't, and I cannot figure out what I might
have done to cause this. [Oh, for a revert to history!] The line where a
control's value is set (Forms!frmmomsbabies!ctlSubBabies.Form!mom_id =
intMomId) is the one that now gives the error "You entered and expression
that has an invalid reference to the property Form/Report." In debugging,
typename(Forms!frmmomsbabies!ctlSubBabies) is SubForm, but appending .Form to
it yields an error.
Any & all clues are more than welcome.
TIA.
George