以文本方式查看主题 - Foxtable(狐表) (http://foxtable.net/bbs/index.asp) -- 专家坐堂 (http://foxtable.net/bbs/list.asp?boardid=2) ---- 权限设置 (http://foxtable.net/bbs/dispbbs.asp?boardid=2&id=23312) |
||||
-- 作者:hawkerwin -- 发布时间:2012/9/8 16:45:00 -- 权限设置 Dim cmd As New SQLCommand Dim exp As String = "(编辑者 Is Null Or 编辑者 = \'" & User.Name & "\') And [_Identify] = " & e.Row("_Identify") cmd.CommandText = "Update {员工} Set 编辑者 = \'" & User.Name & "\' Where " & exp If cmd.ExecuteNonQuery = 1 Then Forms("编辑窗口").Open() Else cmd.CommandText = "Select 编辑者 From {员工} Where [_Identify] = " & e.Row("_Identify") Dim nm As String = cmd.ExecuteScalar If nm > "" Then MessageBox.show(nm & "正在编辑此行!","提示",MessageBoxButtons.OK,MessageBoxIcon.Information) Else cmd.CommandText = "Select Count(*) From {员工} Where [_Identify] = " & e.Row("_Identify") If cmd.ExecuteScalar =0 Then MessageBox.show("此行已被他人删除!","提示",MessageBoxButtons.OK,MessageBoxIcon.Information) End If End If End If
使用外部数据源的时候出现错误,需要怎么修改?
|
||||
-- 作者:狐狸爸爸 -- 发布时间:2012/9/8 16:48:00 -- 看看:
http://www.foxtable.com/help/topics/2344.htm
|
||||
-- 作者:hawkerwin -- 发布时间:2012/9/8 16:51:00 -- 谢谢护理爸爸 |