以文本方式查看主题 - Foxtable(狐表) (http://foxtable.com/bbs/index.asp) -- 专家坐堂 (http://foxtable.com/bbs/list.asp?boardid=2) ---- [求助]目录树节点NodeMouseClick (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=170662) |
-- 作者:lgj716330 -- 发布时间:2021/8/3 18:23:00 -- [求助]目录树节点NodeMouseClick 同一个目录树下,有打开表的,也有打开窗口的,怎样把下面两段结合一起,判断如果是表的就打开表,如果是窗口的就打开窗口 Se/ect Case e.Node.Name Case e.Node.Name Dim dr As DataRow dr = DataTables("报表权限").Find("报表 = \'" & e.Node.Name & "\'") If dr IsNot Nothing Then Dim fl As String = dr("分组") Dim ck As String = dr("查看权限") If Functions.Execute("ShouQuan",fl,ck) Then MainTable = Tables(e.Node.Name) Else MessageBox.Show("你无此表查阅权限!") End If End If End Se/ect Se/ect Case e.Node.Name Case e.Node.Name Dim dr As DataRow dr = DataTables("报表权限").Find("报表 = \'" & e.Node.Name & "\'") If dr IsNot Nothing Then Dim fl As String = dr("分组") Dim ck As String = dr("查看权限") If Functions.Execute("ShouQuan",fl,ck) Then Forms(e.Node.Name).Open() MainTable = Tables("查询表") Else MessageBox.Show("你无此表查阅权限!") End If End If End Se/ect |
-- 作者:lgj716330 -- 发布时间:2021/8/3 18:45:00 -- 明白了 Select Case e.Node.Name Case e.Node.Name Dim dr As DataRow dr = DataTables("报表权限").Find("报表 = \'" & e.Node.Name & "\'") If dr IsNot Nothing Then Dim fl As String = dr("分组") Dim ck As String = dr("查看权限") If Functions.Execute("ShouQuan",fl,ck) And Forms.Contains(e.Node.Name)=False Then MainTable = Tables(e.Node.Name) ElseIf Functions.Execute("ShouQuan",fl,ck) And Forms.Contains(e.Node.Name) Then Forms(e.Node.Name).Open() MainTable = Tables("查询表") Else MessageBox.Show("你无此表查阅权限!") End If End If End Select |