If e.Form.Controls("Button1").Name = "合并" Then
For Each r As Row In Tables("窗口1_table1").Rows
If r.isnull("名称") = False AndAlso r.isnull("数字") = False AndAlso r("名称").Contains("-") = False Then \'避免多次合并
r("名称") = r("数字") + "-" + r("名称")
End If
Next
e.Form.Controls("Button1").Name = "分离"
Else
For Each r As Row In Tables("窗口1_table1").Rows
If r.isnull("名称") = False AndAlso r.isnull("数字") = False AndAlso r("名称").Contains("-") = True Then \'避免多次分离
Dim s = r("名称")
Dim s1() As String
s1 = s.split("-")
r("名称") = s1(1)
End If
Next
e.Form.Controls("Button1").Name = "合并"
End If