Click or drag to resize
Galactic API

DirectoryBlockInheritance Method

Blocks inheritance on this directory.

Namespace:  Galactic.FileSystem
Assembly:  Galactic.FileSystem (in Galactic.FileSystem.dll) Version: 1.3.0.499 (1.3.0.499)
Syntax
public static bool BlockInheritance(
	string path,
	ref DirectorySecurity security,
	bool addInheritedPermissions,
	bool commitChanges
)

Parameters

path
Type: SystemString
The path to the directory to block inheritance on.
security
Type: System.Security.AccessControlDirectorySecurity
The DirectorySecurity object of the directory that will be changed.
addInheritedPermissions
Type: SystemBoolean
If true, copies the directory's inherited permissions as explicit permissions on the directory.
commitChanges
Type: SystemBoolean
Indicates whether changes should be commited to this entry. Useful when combining multiple commands.

Return Value

Type: Boolean
True if inheritance was blocked on the directory, false if the directory does not exist, or inheritance could not be blocked.
See Also