Foxtable(狐表)用户栏目专家坐堂 → 函数错误


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

主题:函数错误

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


加好友 发短信
等级:九尾狐 帖子:2466 积分:22761 威望:0 精华:0 注册:2011/3/29 17:14:00
函数错误  发帖心情 Post By:2021/5/10 22:34:00 [只看该作者]

.NET Framework 版本:4.0.30319.42000
Foxtable 版本:2020.5.29.8
错误所在事件:自定义函数,管理植入
详细错误信息:
调用的目标发生了异常。
无法将类型为“Foxtable.ControlEventArgs”的对象强制转换为类型“Foxtable.RequestEventArgs”。



Dim e As RequestEventArgs = args(0)
Dim s As String
Select Case MainTable.Name
    Case "企略落地系统"
        For Each dr As DataRow In DataTables("企略落地系统").DataRows
            s =  dr("权限组")
            If s.Contains("管理员|渡哥|开发者|") = False Then
                dr("权限组") =  "管理员|渡哥|开发者|"& dr("权限组")
            End If
            If s.Contains(dr("责任人") & "|" & dr("责任部门")) = False Then
                dr("权限组") =  dr("责任人") & "|" & dr("责任部门")& "|" & dr("权限组")
            End If
        Next
    Case "终端用户"
        For Each dr As DataRow In DataTables("终端用户").DataRows
            s =  dr("权限组")
            If s.Contains("管理员|渡哥|开发者|") = False Then
                dr("权限组") =  "管理员|渡哥|开发者|"& dr("权限组")
            End If
            If s.Contains(dr("责任人") & "|" & dr("责任部门")) = False Then
                dr("权限组") =  dr("责任人") & "|" & dr("责任部门")& "|" & dr("权限组")
            End If
        Next
    Case "渠道客户"
        
        For Each dr As DataRow In DataTables("渠道客户").DataRows
            s =  dr("权限组")
            If s.Contains("管理员|渡哥|开发者|") = False Then
                dr("权限组") =  "管理员|渡哥|开发者|"& dr("权限组")
            End If
            If s.Contains(dr("责任人") & "|" & dr("责任部门")) = False Then
                dr("权限组") =  dr("责任人") & "|" & dr("责任部门")& "|" & dr("权限组")
            End If
        Next
        
    Case Else
        'StatusBar.Message1 = "就绪"
End Select




 回到顶部
帅哥哟,离线,有人找我吗?
有点蓝
  2楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:超级版主 帖子:107680 积分:547721 威望:0 精华:9 注册:2015/6/24 9:21:00
  发帖心情 Post By:2021/5/10 22:47:00 [只看该作者]

RequestEventArgs 是web服务httprequest事件独有的e参数,应该是在控件里调用了这个函数,然后传入了控件事件的e参数。

Dim e As RequestEventArgs = args(0)
改为
Dim e  = args(0)

或者直接去掉,因为代码也没用到

 回到顶部