Example Title |
Copy Code
|
---|---|
/* * How to call: AddProjectUser("userAdd", "QATester"); */ private void AddProjectUser(String newProjectUser, String addToUserGroup) { ICustomization objCust = (ICustomization)tdConnection.Customization; ICustomizationUsers objUsers = (ICustomizationUsers)objCust.Users; objUsers.AddUser(newProjectUser); ICustomizationUsersGroups objUsersGroups = (ICustomizationUsersGroups)objCust.UsersGroups; ICustomizationUsersGroup objUsersGroup = (ICustomizationUsersGroup)objUsersGroups.Group[addToUserGroup]; objUsersGroup.AddUser(newProjectUser); objCust.Commit(); } |