Foxtable(狐表)用户栏目专家坐堂 → 自动复制


  共有4414人关注过本帖树形打印复制链接

主题:自动复制

帅哥哟,离线,有人找我吗?
Bin
  1楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:贵宾 帖子:35433 积分:178530 威望:0 精华:3 注册:2013/3/30 16:36:00
  发帖心情 Post By:2013/11/27 16:32:00 [显示全部帖子]

If e.DataCol.Name = "数量" Then
    If e.DataRow.Isnull("数量") = False
    Dim n As Integer = e.DataRow("数量")
    Dim nma() As String = {"入库单号","名称","规格"}
    Dim nmb() As String = {"入库单号","名称","规格"}
    dim drlist as List(of datarow) = DataTables("固定资产库存").select("入库单号='" & e.datarow("入库单号") & "'")
    if drlist is nothing then
    for i as integer = 1 to n then
    Dim dr As DataRow = DataTables("固定资产库存").AddNew()
    For i As Integer = 0 To nma.Length - 1
        dr(nmb(i)) = e.DataRow(nma(i))
    Next
    next
    else
    if drlist.count>n then
       for i as integer=0 to drlist.count-n-1
           drlist(i).Delete
       next
    end if
    end if
  End If
End If

 回到顶部