public static void AddUserToRole(string username, string rolename) { ZcrlRoleProvider roleProvider = new ZcrlRoleProvider(); roleProvider.AddUsersToRoles(new string[] { username }, new string[] { rolename }); }
public static void RemoveUserFromRole(string username, string roleName) { ZcrlRoleProvider roleProvider = new ZcrlRoleProvider(); roleProvider.RemoveUsersFromRoles(new string[] { username }, new string[] { roleName }); }