您的位置:首页 > 运维架构

InfoPath display or hide some section according to whether current user belong to SharePoint group

2012-11-06 20:59 357 查看
We have a lot of requirements to check if user is in some SharePoint group then display or hide some section in the InfoPath form.

This article will show you the steps to do it.

For how to get the SharePoint group in the InfoPath form please check http://blog.csdn.net/farawayplace613/article/details/8149167 .
This article is base on the result of the above article.

1. Create a SharePoint group in your SharePoint site, name the group as Admin, add your account into that group

2. Open the InfoPath form of the list,(see how to do it in my previous blog)

3. Add a section into the InfoPath form



 

4.Add some text into the added section, and add one text box into, rename the text box as IsAdmin

5. Click the data tab, and click the "Form Load"

6. Add rule and name it as "SetIsAdmin"

7. Click the add action and select the "Set a filed's value"



 

8. Select the added section, add a rule(select format for rule type), name it as IsAdmin.



9. Click the qiuck publish button of the InofPath form.

10. Try to create new  item of the list, the admin section should be showed:



 

11. Remove your account from the admin group, try to add a new item again, now you can't see the admin section:

 



 

 
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐