Foxtable(狐表)用户栏目专家坐堂 → 没有Table


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

主题:没有Table

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


加好友 发短信
等级:童狐 帖子:203 积分:1368 威望:0 精华:0 注册:2017/12/4 15:36:00
没有Table  发帖心情 Post By:2017/12/11 13:40:00 [只看该作者]

  我对公司的一些表单进行了隐藏或禁止运行,结果有的用户打开受限的界面后会提示这个,请问是怎么回事
图片点击可在新窗口打开查看此主题相关图片如下:qq图片20171211133303.png
图片点击可在新窗口打开查看

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


加好友 发短信
等级:版主 帖子:85326 积分:427815 威望:0 精华:5 注册:2012/10/18 22:13:00
  发帖心情 Post By:2017/12/11 14:43:00 [只看该作者]

你是如何隐藏或者禁止的?说明你的操作或者提出代码。

 回到顶部
帅哥哟,离线,有人找我吗?
雅痞123456
  3楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:童狐 帖子:203 积分:1368 威望:0 精华:0 注册:2017/12/4 15:36:00
  发帖心情 Post By:2017/12/12 7:49:00 [只看该作者]

项目管理 项目属性
图片点击可在新窗口打开查看此主题相关图片如下:1.png
图片点击可在新窗口打开查看

If e.DataTableName = "员工名单"  Then
    If e.User.Group = "财会部" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "工资表" Then
    If e.User.Group = "库管人员" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "产品工艺表" Then
    If e.User.Group = "财会部" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "刀具出入库表" Then
    If e.User.Group = "财会部" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "工艺卡片发放记录" Then
    If e.User.Group = "财会部" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "刀具管理明细" Then
    If e.User.Group = "财会部" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "员工名单" Then
    If e.User.Group = "库管人员" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "随件卡" Then
    If e.User.Group = "库管人员" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "工艺卡片发放记录" Then
    If e.User.Group = "库管人员" Then
        e.Cancel = True
    End If
End If


If e.DataTableName = "产品工艺表" Then
    If e.User.Group = "库管人员" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "员工月工时表" Then
    If e.User.Group = "库管人员" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "员工名单" Then
    If e.User.Group = "车间工艺人员" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "成品出入库表" Then
    If e.User.Group = "车间工艺人员" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "库存表" Then
    If e.User.Group = "车间工艺人员" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "员工月工时表" Then
    If e.User.Group = "车间工艺人员" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "工资表" Then
    If e.User.Group = "车间工艺人员" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "成品出入库表" Then
    If e.User.Group = "车间工艺人员" Then
        e.Cancel = True
    End If
End If

If e.DataTableName = "随件卡" Then
    If e.User.Group = "车间工艺人员" Then
        e.Cancel = True
    End If
End If


  写的太笨了  还望见谅


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


加好友 发短信
等级:版主 帖子:85326 积分:427815 威望:0 精华:5 注册:2012/10/18 22:13:00
  发帖心情 Post By:2017/12/12 9:17:00 [只看该作者]

不要这样做,你这样做,是不加载对应的表,但如果你有代码需要使用到对应的表,就会报错。

 

建议隐藏,而不是不加载。

 

http://www.foxtable.com/webhelp/scr/2267.htm

 

http://www.foxtable.com/webhelp/scr/1600.htm

 


 回到顶部
帅哥哟,离线,有人找我吗?
雅痞123456
  5楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:童狐 帖子:203 积分:1368 威望:0 精华:0 注册:2017/12/4 15:36:00
  发帖心情 Post By:2017/12/12 9:45:00 [只看该作者]

Select Case User.Group
    Case "车间工艺人员","车间管理人员","采购部", "库管人员" ,"操作者" 
        Tables("工资表").Visible = False
        Tables("随件卡").Visible = False
        Tables("员工月工时表").Visible = False
        Tables("员工名单").Visible = False
        Tables("产品表").Visible = False
    Case "操作者"
        Tables("随件卡").Visible = False
        Tables("员工月工时表").Visible = False
        Tables("工资表").Visible = False
        Tables("库存表").Visible = False
    Case "统计员"
        Tables("员工月工时表").Visible = False
        Tables("库存表").Visible = False
        Tables("刀具出入库表").Visible = False
        Tables("工资表").Visible = False
    Case Else
        Tables("随件卡").Visible = True
        Tables("员工月工时表").Visible = True
        Tables("工资表").Visible = True
        Tables("产品工艺表").Visible = True
End Select


这样可以吗

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


加好友 发短信
等级:版主 帖子:85326 积分:427815 威望:0 精华:5 注册:2012/10/18 22:13:00
  发帖心情 Post By:2017/12/12 9:59:00 [只看该作者]

可以得,写到LoadUserSetting事件即可。

 回到顶部