父表BeforeSaveDataRow事件代码:
e.DataRow.Locked = True '父表当前行行Dim drs As List(Of DataRow)drs = DataTables("子表").Select("[关联列] = '" & e.DataRow("关联列") & "'")For Each dr As DataRow In drs dr.Locked = True Next 子表和关联列名称自己修改,关联列为非字符型数据时,注意修改条件表达式!