Share via


FbwfRestoreFile

5/10/2007

Resets the cached view of the specified file.

Syntax

ULONG FbwfRestoreFile(
   PWCHAR volume,
   PWCHAR path
};

Parameters

  • volume
    [in] NULL terminated wide string containing the volume name.
  • path
    [in] NULL terminated wide string containing the file name or directory.

Return Value

This function may return the following:

Return value Description

NO_ERROR

The operation completed successfully.

ERROR_ACCESS_DENIED

The specified file is not currently being cached by the FBWF.

ERROR_FILE_NOT_FOUND

If path refers to a directory or non-existent file.

ERROR_INVALID_DRIVE

The specified volume is valid but does not exist or is not protected.

ERROR_INVALID_FUNCTION

If the parameter path refers to is a write-through file, a file which has been renamed, or a cached file which does not exist on the physical media.

ERROR_INVALID_PARAMETER

If the volume or path parameter is NULL.

ERROR_READ_ONLY

If path refers to a read-only file.

Remarks

This function effectively discards the cached image of the specified file. When the file is again written to, the cache will be rebuilt from the physical image and the changes will take place on the cached image.

Requirements

OS Versions: Windows XP Embedded, WEPOS.

Header: fbwfapi.h.

Link Library: fbwflib.lib.

See Also

Reference

FbwfCommitFile

Concepts

FBWF API