你好,为什么这个删除的代码不执行呢?
If Tables("委托接收").Current("委托状态") = "待上传" OrElse Tables("委托接收").Current("委托状态") = "退回" Then
If Tables("委托接收").Current("结构代码") = "TCQ"
Dim r As Integer
r = Tables("填充墙锚固力委托").FindRow("[结构代码] = '" & Tables("委托接收").Current("结构代码") & "'") '从 第一行开始查找
If r >= 0 Then '如果找到的话
Tables("填充墙锚固力委托").Position = r '定位到找到的行.
If MessageBox.Show("是否删除?","请确认",MessageBoxButtons.YesNo,MessageBoxIcon.Question) = DialogResult.Yes Then
Tables("填充墙锚固力委托").Current.Delete
End If
End If
End If
End If