If(_UserRole ="管理员"){
''人员表
DataTables("person").LoadFilter = "organ = '" & _UserOrgan & "'" Or
DataTables("person").Load()
''单位表
DataTables("organList").LoadFilter = "organName = '" & _UserOrgan & "'"
DataTables("organList").Load()
''历史库表
DataTables("history").LoadFilter = "organ= '" & _UserOrgan & "'"
DataTables("history").Load()
''用户表
DataTables("user").LoadFilter = "userOrgan = '" & _UserOrgan & "'"
DataTables("user").Load()
}
ElseIf(_UserRole ="操作员"){
''人员表
DataTables("person").LoadFilter = "organ = '" & _UserOrgan & "'"
DataTables("person").Load()
''单位表
DataTables("organList").LoadFilter = "organName = '" & _UserOrgan & "'"
DataTables("organList").Load()
''历史库表
DataTables("history").LoadFilter = "organ= '" & _UserOrgan & "'"
DataTables("history").Load()
''用户表
DataTables("user").LoadFilter = "userOrgan = '" & _UserOrgan & "'"
DataTables("user").Load()
}
End If
红色报错,_userRole是全局代码,