撤销不执行
插入按钮代码如下:
Dim sort As String = Tables("工程款申请").sort
Dim r As Row = Tables("工程款申请").Current
Tables("工程款申请").AllowMerge =False
Tables("工程款申请").sort = ""
Dim nr As Row = Tables("工程款申请").InsertNew
nr.Move(r.Index + 0)
Dim cs() As String = {"序号","项目编码","所属机构","项目名称","建设单位","合同金额","合同工期","开工日期","竣工日期"}
For Each c As String In cs
nr(c) = r(c)
Next
Tables("工程款申请").AllowMerge = True
Tables("工程款申请").Sort = "序号,项目编码,所属机构"
撤销按钮代码如下:
With Tables("工程款申请")
If .Current IsNot Nothing Then
.Current.Reject()
End If
End With
'恢复合模式
Tables("工程款申请").AllowMerge = True
Tables("工程款申请").Sort = "序号,项目编码,所属机构"
现在撤销按钮撤销不了新插入的行。
[此贴子已经被作者于2017/5/15 17:01:32编辑过]