以文本方式查看主题

-  Foxtable(狐表)  (http://www.foxtable.com/bbs/index.asp)
--  专家坐堂  (http://www.foxtable.com/bbs/list.asp?boardid=2)
----  [求助]如何将字典中的元素(row类型)插入到table中  (http://www.foxtable.com/bbs/dispbbs.asp?boardid=2&id=62596)

--  作者:loongtai
--  发布时间:2015/1/5 10:03:00
--  [求助]如何将字典中的元素(row类型)插入到table中
Dim dic As new Dictionary(of String,Row)
With Tables("A")
    For Each r As Row In .rows
        dic.add(r("编号"),r)
    Next
End With
With Tables("B")
    For Each r As Row In .rows
        If dic.containskey(r("编号"))=False Then
            \'将dic(r("编号"))添加到tables("B")中
            ????????????????
        End If
    Next
End With


--  作者:有点甜
--  发布时间:2015/1/5 10:07:00
--  

 不能直接插入。

 

 1、新增一行;

 

 2、循环每一列,赋值进去


--  作者:Bin
--  发布时间:2015/1/5 10:08:00
--  
不需要这么麻烦

 下载信息  [文件大小:   下载次数: ]
点击浏览该文件:新建文本文档.txt


[此贴子已经被作者于2015-1-5 10:09:14编辑过]