Principal::Save Method ()

 

Saves the changes that were made on the principal object to the store. If this is a new principal object, this method inserts it into the store.

Namespace:   System.DirectoryServices.AccountManagement
Assembly:  System.DirectoryServices.AccountManagement (in System.DirectoryServices.AccountManagement.dll)

public:
[SecurityCriticalAttribute]
void Save()

Exception Condition
InvalidOperationException

The principal has not yet been associated with a PrincipalContext object.

This type of principal cannot be inserted in the store.

PrincipalOperationException

An exception occurred when saving changes tnso the store, or updating the group membership in the store.

PrincipalExistsException

The principal already occurs in the store.

PasswordException

The password does not meet complexity requirements.

.NET Framework
Available since 3.5

System.DirectoryServices.AccountManagement
Save Overload
Principal Class
System.DirectoryServices.AccountManagement Namespace Overview

Return to top
Show: