函数参考


_WinAPI_EncryptionDisable

Disables or enables encryption of the specified directory and the files in it.

#Include <WinAPIEx.au3>
_WinAPI_EncryptionDisable ( $sDir, $fDisable )

参数

$sDir The name of the directory for which to enable or disable encryption. If this parameter specifies
a file, the attempt will fail.
$fDisable Specifies whether to disable or enable encryption, valid values:
TRUE - Disable.
FALSE - Enable.

返回值

成功: 返回 1.
失败: 返回 0 并设置 @error 标志为非 0 值.

注意/说明

If encryption is disabled, the function will write the following to the Desktop.ini file in the directory
(creating it if necessary):

[Encryption]
Disable=1

The user can also manually add or edit the above lines in the Desktop.ini file and produce the same effect.
Thereafter, _WinAPI_EncryptFile() function will fail on the directory and the files in it, and the last error
code will be ERROR_DIR_EFS_DISALLOWED (6010). This function does not affect encryption of subdirectories
within the given directory.

If encryption is enabled, the function will write the following to the Desktop.ini file:

[Encryption]
Disable=0

相关

详情参考

在MSDN中搜索