Foxtable(狐表)用户栏目专家坐堂 → 数据同步问题


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

主题:数据同步问题

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


加好友 发短信
等级:管理员 帖子:47497 积分:251403 威望:0 精华:91 注册:2008/6/17 17:14:00
  发帖心情 Post By:2013/4/19 16:08:00 [显示全部帖子]

在DataColchanged事件中设置代码:

 

Select Case e.DataCol.name
    Case "长","高", "宽"
        Dim nms() As String = {"a","b","c","e","f"}
        For Each nm As String In nms
            Dim cmd As New SQLCommand
            cmd.Connection Name = "数据源"
            cmd.CommandText = "Update " & nm & " Set " & e.DataCol.name & " = '" & e.NewValue & "'"
            cmd.ExecuteNonQuery
        Next
End Select


 回到顶部