This is probably straightforward, but I must be missing something.
* Master form (one record per school) to enter test data (bound to a school location code)
* Combo drop-down box shows schools without scores (OnCurrent runs a Requery to repopulate the combo box after each new record)
* After choosing school, Sub form to enter test types/scores
User enters new master record, chooses the school, then skips entering the test scores on the subform. Since the master record exists, moving to a new record (requery) correctly drops it from the combo box, and the user asks "how come I can't see school xx?" (Sometimes error trapping is better than constant reminders.)
THE QUESTION... which form action is appropriate to validate that there are sub-records before moving to the next master record? (Code is below, and logic works, just can't get the order right...) Since the user can bounce between master and subform, I really want to catch it when they move to a new master record.
Dim subreccount As Integer
subreccount = Forms!Workspace![Workspace subform].Form.RecordsetClone.RecordCount
If (subreccount = 0) Then
MsgBox ("Please choose a different school or paste the P223 data")