views:

1695

answers:

1

I have a project where I need to add users to a SharePoint portal, but when I add them, I also need to set addition parameters inside a separate database.

I want to add a custom administration screen where the administration can set these values when they add the user rather than forcing them to first add the user then go to a separate interface page where they set the values.

Does anyone know of any good articles that will explain how to accomplish this?

Thanks.

+1  A: 

It would be easier to create a custom asp.net form that would get all the information required about the user. the submit could then add the information to the database that is needed and use the object model to add the users.

SPRoleAssignment MyRoleAssign = new SPRoleAssignment(”domain/alias”, “email address”, “User Name”, “Description”);
SPRoleDefinition MyRoleDef = newSubWeb.RoleDefinitions["Contribute"];    
MyRoleAssign.RoleDefinitionBindings.Add(MyRoleDef);    
site.RoleAssignments.Add(MyRoleAssign);

Code from farhanfaiz.wordpress.com here

Otherwise the SharePoint webservices may do. Examples here

Nat
Sweet, that looks like what I'm looking for. Thanks for the code and links.
Ryan Smith