다음을 통해 공유


AddEntity Method

Topic Last Modified: 2006-06-13

Adds a copy of an entity object to a DACL object s entity collection.

Applies To

DACL Object

Syntax


objResult  objDACL.AddEntity(objEntity);

Parameters

  • objEntity
    An entity object to add to the DACL object.

Return Value

An object that returns error codes and descriptions.

Example

var e = objDacl2.SearchForObjectByNT4Name("MyDomain\\User1");
var objResult = objDacl.AddEntity(e);
if( 1 == objResult.number) {
    
// 0 means user was added, no errors
// 1 means no error, but the user was not added   might be a duplicate
}