开发者

how to set read only properties to the particular info path form control based on user logged in?

how to set read only properties to the particular info path form contr开发者_Go百科ol based on user logged in?


Your best option (assuming you are using managed code) is to get the user name with either Application.User.UserName or HttpContext.Current.User.Identity and then call IsInRole (I believe it is a member of the WindowsPrincipal class).

Save the result into the value of a field and you can then use the standard conditional formatting to lock the fields you don't want the users changing. I also usually conditionally change the look of those readonly fields (grey background fill etc) so the users don't get confused and think they can edit.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜