-- [求助]回复:(有点甜)Dim Filter As StringWith e.Form....
此主题相关图片如下:dix`akmgm{r_}_x_gdo`s}p.png
Dim Cols1() As String = {"入库编号","品名规格","工序","单位","入库单价","客户数量","过磅数量","应收金额","出库"}
Dim Cols2() As String = {"入库编号","品名规格","工序","单位","入库单价","客户数量","过磅数量","应收金额","出库"}
For Each dr1 As DataRow In DataTables("入库明细表").Select("[出库] = true")
Dim dr2 As DataRow = DataTables("出库明细表").AddNew()
For i As Integer = 0 To Cols1.Length -1
dr2(Cols2(i)) = dr1(Cols1(i))
Next
dr1("已出库") = True
Next
Dim Filter As String
With e.Form.Controls("TextBox1")
If .text IsNot Nothing Then
If Filter >"" Then
Filter = Filter & " And "
End If
Filter = Filter & "客户 = \'" & .text & "\'"
End If
End With
If Filter > "" Then
DataTables("出库明细表").LoadFilter = Filter
DataTables("出库明细表").Load
End If
DataTables("入库明细表").ReplaceFor("出库", False, "[出库] = true")
\'Tables("出库明细表").Sort = "入库日期"
Dim r As Table = Tables("出库明细表")
r.Position = r.rows.count-1
Dim d As Table = Tables("编辑录入窗口_出库明细表")
d.Position = d.rows.count-1