If I have two tables in my project to have access to such a blog (blog writers access) and one for friends access. 开发者_高级运维I use if I want the RoleProvider What is the form?
This question is very ambiguous and suggestions you need to do some reading on ASP.NET membership/roles... but to check if the user is in a role, you just do this:
User.IsInRole("role name")
Roles.Provider
gets the default Role Provider.
Roles.Providers
gets the collection of Role Providers for the ASP.NET application.
Look into the System.Web.Security
namespace
精彩评论