以文本方式查看主题 - Foxtable(狐表) (http://foxtable.com/bbs/index.asp) -- 专家坐堂 (http://foxtable.com/bbs/list.asp?boardid=2) ---- 求助:如何设定只有"开发者"才可使用删除按钮? (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=54609) |
-- 作者:peterx -- 发布时间:2014/7/31 14:37:00 -- 求助:如何设定只有"开发者"才可使用删除按钮? 下代码是删除按钮的代码?如何增加对当前用户的判断,若不是“开发者”,则不允许删除。谢谢 With Tables("总表") If .Current IsNot Nothing Then .Current.Delete End If End With
|
-- 作者:有点甜 -- 发布时间:2014/7/31 14:39:00 -- If user.Type = UserTypeEnum.Developer Then With Tables("总表") If .Current IsNot Nothing Then .Current.Delete End If End With Else msgbox("你不是开发者") End If |
-- 作者:peterx -- 发布时间:2014/7/31 14:40:00 -- 谢谢老师 |