父表的“全宗号”,“老案卷号”与子表的“全宗号”,“老案卷号”关联,在父表CurrentChanged下这样写对么?
If Forms("照片档案目录著录界面").Opened() '一定要判断用于模拟关联表的窗口是否已经打开
Dim rdo As WinForm.RadioButton = Forms("照片档案目录著录界面").Controls("RadioButton1关联")
Dim t As Table = Tables("照片档案目录著录界面_Table1")
If rdo.Checked = True Then
With Tables("照片档案目录")
If .Current Is Nothing Then
t.Filter = "[_Identify] Is Null"
Else
t.Filter = "全宗号 = '" & .Current("全宗号") & "'"
t.Filter = "老案卷号 = '" & .Current("老案卷号") & "'"
End If
End With
End If
End If