Re: Add/Remove Groups
Shawn Wildermuth <[email protected]>
| Newsgroups | gmane.comp.windows.devel.dotnet.cx |
|---|---|
| Message-ID | <001101c6c009$52607690$6825ff0a@theadoguy> |
If you use System.DirectoryServices, it should be simplier that that. But I don't have example code with me. Thanks, Shawn Wildermuth Wildermuth Consulting Services, LLC http://adoguy.com C# MVP, MCSD.NET, Author and Speaker > -----Original Message----- > From: Discussion relating to the specifics of the C# and > Managed C++ languages [mailto:[email protected]] > On Behalf Of Mont Rothstein > Sent: Monday, August 14, 2006 8:41 PM > To: [email protected] > Subject: [DOTNET-CX] Add/Remove Groups > > I want to be able to add and remove groups from users (or > users from groups depending on your perspective) from within > a .NET application. The users will be part of a domain and > the user wanting to add/remove groups will be an admin. > > I can find the user name and SID by searching the directory > server, but I can't figure out how to add/remove the groups. > > I can use LogonUser() to get the access token, and then get > the WindowsIdentity(), but that requires that I have the > user's password. > > Does anyone know how to do this without having each user's password? > > Thanks, > -Mont > > =================================== > This list is hosted by DevelopMentorR http://www.develop.com > > View archives and manage your subscription(s) at > http://discuss.develop.com =================================== This list is hosted by DevelopMentor® http://www.develop.com View archives and manage your subscription(s) at http://discuss.develop.com