beforeSaveDataRow事件
If e.DataRow.GetParentRow("表B") Is Nothing Then msgbox("没有父表数据") e.cancel = TrueEnd If