Foxtable(狐表)用户栏目专家坐堂 → [求助]请问如下两个代码怎么合并


  共有3963人关注过本帖平板打印复制链接

主题:[求助]请问如下两个代码怎么合并

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


加好友 发短信
等级:童狐 帖子:200 积分:1414 威望:0 精华:0 注册:2014/10/7 21:19:00
[求助]请问如下两个代码怎么合并  发帖心情 Post By:2015/1/13 8:32:00 [只看该作者]

If e.DataCol.name="产品图号" Then
    Tables("图纸信息表").Filter="产品图号 like '%" & e.DataRow("产品图号") & "%'"
End If



If e.NewValue Is Nothing Then
        e.DataRow("名称") = Nothing
        e.DataRow("材料") = Nothing
    Else
        Dim dr As DataRow
        dr = DataTables("图纸信息表").Find("产品图号 = '" & e.DataRow("产品图号") & "' and 名称 is not null")
        If dr IsNot Nothing
            e.DataRow("名称") = dr("名称")
        End If
        dr = DataTables("图纸信息表").Find("产品图号 = '" & e.DataRow("产品图号") & "' and 材料 is not null")
        If dr IsNot Nothing
            e.DataRow("材料") = dr("材料")
        End If
End If

第二个代码是我想加的


 回到顶部
总数 16 1 2 下一页