IFileSystemImage::Exists method (imapi2fs.h)

Checks for the existence of a given file or directory.

Syntax

HRESULT Exists(
  [in]  BSTR        fullPath,
  [out] FsiItemType *itemType
);

Parameters

[in] fullPath

String that contains the fully qualified path of the directory or file to check.

[out] itemType

Indicates if the item is a file, a directory, or does not exist. For possible values, see the FsiItemType enumeration type.

Return value

S_OK is returned on success, but other success codes may be returned as a result of implementation. The following error codes are commonly returned on operation failure, but do not represent the only possible error values:

Return code Description
E_POINTER
Pointer is not valid.

Value: 0x80004003

IMAPI_E_INVALID_PARAM
The value specified for parameter %1!ls! is not valid.

Value: 0xC0AAB101

IMAPI_E_INVALID_PATH
The specified path is not fully qualified. The path must begin with '\\' or '/' to indicate the image root, or the images position within a directory structure.

Value: 0xC0AAB110

IMAPI_E_DIR_NOT_FOUND
The directory '%1!s!' not found in FileSystemImage hierarchy.

Value: 0xC0AAB11A

E_NOINTERFACE
The object doesn't support this interface.

Value: 0x80004002

Requirements

Requirement Value
Minimum supported client Windows Vista, Windows XP with SP2 [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Target Platform Windows
Header imapi2fs.h

See also

FsiItemType

IFileSystemImage