如果是主窗口,就必须先切换表。
Dim lvw As WinForm.ListView = e.Form.Controls("ListView1")
If lvw.Current IsNot Nothing Then
If Forms.Contains("'" & lvw.Current.Text & "'") Then
MainTable = Tables("表A")
Forms("'" & lvw.Current.Text & "'").Open()
Else
MessageBox.Show( "《" & lvw.Current.Text & " 》模块正在设计中......","提示")
End If
End If