Home Dashboard Directory Help
Search

Unknown PrincipalOperationException when add UserPrincipal in collection GroupPrincipal.Members by DE-Soft


Status: 

Closed
 as Duplicate Help for as Duplicate


4
0
Sign in
to vote
Type: Bug
ID: 610995
Opened: 10/6/2010 3:34:35 AM
Access Restriction: Public
2
Workaround(s)
view
5
User(s) can reproduce this bug

Description

The operation GroupPrincipal.Members.Add(UserPrincipal) raise unknown Exception 0x80005000 in Net 4.0-Source System.DirectoryServices.AccountManagement.
- ActiveDirectory: Windows 2003 Domain on Windows Server 2003 R2,
- Application on Domainclients: Windows XP Prof SP3 or Windows 7 Prof,
- All systems full patched via WSUS 3.0 SP2 with complet Framework to NET 4.
Application as 3.5-Framework run posible.

thx Daniel
Details
Sign in to post a comment.
Posted by DE-Soft on 9/11/2012 at 10:12 AM
Repeat, where is the link to the duplicate? Problem is not fixed in NET 4.0!!!

Grmpf. Dani
Posted by JTokach on 8/26/2011 at 1:32 PM
Repeat, where is the link to the duplicate? Has this been fixed? Running VS2010.
Posted by SimonCropp on 2/2/2011 at 4:44 PM
Where is the link to the duplicate
Posted by david-ptbc on 1/4/2011 at 1:46 PM
What is the status of this??
This says "Resolved As Duplicate" -- so where is the duplicate that has the fix instead of the work around??
Posted by Microsoft on 1/4/2011 at 11:57 AM
Thank you for your feedback comments! We were able to repro the issue and will be looking to fix this issue in a future release. If this issue is urgent, please contact support directly(http://support.microsoft.com).
Posted by Microsoft on 10/6/2010 at 10:46 PM
Thank you for reporting the issue.
We are routing this issue to the appropriate group within the Visual Studio Product Team for triage and resolution.These specialized experts will follow-up with your issue.
Posted by Microsoft on 10/6/2010 at 4:21 AM
Thank you for your feedback, we are currently reviewing the issue you have submitted. If this issue is urgent, please contact support directly(http://support.microsoft.com)
Sign in to post a workaround.
Posted by SourStones on 1/5/2012 at 4:06 PM
Thank you so much. *ThumbsUp*
Posted by SimonCropp on 11/22/2010 at 7:08 PM
instead of using

groupPrincipal.Members.Add(memberPrincipal);
groupPrincipal.Save();

use
using (var groupDirectoryEntry = (DirectoryEntry)groupPrincipal.GetUnderlyingObject())
{
    groupDirectoryEntry.Properties["member"].Add(memberPrincipal.DistinguishedName);
    groupDirectoryEntry.CommitChanges();
}