[This is preliminary documentation and subject to change.]
Initializes a new QuotaControl object by opening the NTFS volume with the requested access rights. The return value indicates whether the volume supports NTFS disk quotas and whether the caller has sufficient access rights.
HRESULT Initialize(
LPCWSTR pszPath,
BOOL bReadWrite
);
This method returns one of the following values.
Value | Meaning |
---|---|
S_OK | Success. |
E_FAIL | Failure reading volume quota information. |
DQC_E_ACCESS_DENIED | The caller has insufficient access rights. |
DQC_E_BAD_PATHNAME | The requested path name is invalid. |
DQC_E_FILE_NOT_FOUND | The requested file or object was not found. |
DQC_E_INITIALIZED | The controller object has already been initialized. Multiple initialization is not allowed. |
DQC_E_INVALID_NAME | The requested file path is invalid. |
DQC_E_NO_QUOTAS_FS | The file system does not support quotas. Currently, the file system must be NTFS. |
DQC_E_NO_QUOTAS_FSVER | The file system version does not support quotas. Currently, the file system must be NTFS 5.0 or later. |
DQC_E_PATH_NOT_FOUND | The requested file path was not found. |
Windows NT: Requires version 5.0 or later.
Windows: Unsupported.
Windows CE: Unsupported.
Header: Declared in dskquota.h.
File Systems Overview, File System Interfaces, IDiskQuotaControl