We can use this method for dealing with users that has low previlages over specific List.
SPSecurity.RunWithElevatedPrivileges(delegate()
{
SPListItem NewUser = NewUsersList.Items.Add();
NewUser["Username"] = _userNameTextBox.Text.Trim();
NewUser["Password"] = _passwordTextBox.Text.Trim();
NewUser["First Name"] = _firstNameTextBox.Text.Trim();
NewUser["Last Name"] = _lastNameTextBox.Text.Trim();
NewUser["Phone"] = _phoneTextBox.Text.Trim();
Site.AllowUnsafeUpdates = true;
NewUser.Update();
}
);
2009/03/10
Add previlages to user to do some actions in WSS 3.0 / MOSS 2007
التسميات:
SharePoint
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment