CallbackRegistry

Control over registry operations in Windows and .NET applications

CallbackRegistry.SetEndOfFile method

Filter:

Pascal    C++ (Lib)    C++ (VCL)    C++ (.NET)    C#    VB.NET   

CallbackRegistry     See also    

Overview

Sets file size bypassing filters.

Declaration

[Pascal]
    function SetEndOfFile(FileHandle: THandle; EndOfFile : Int64) : boolean;

[C++ (Lib)]
    bool SetEndOfFile(HANDLE FileHandle, __int64 EndOfFile);

[C++ (VCL)]
    bool __fastcall SetEndOfFile(SafeFileHandle FileHandle, __int64 EndOfFile);

[C++ (.NET)]
    bool SetEndOfFile(SafeFileHandle^ FileHandle, Int64 EndOfFile);

[C#]
    bool SetEndOfFile(SafeFileHandle FileHandle, Int64 EndOfFile);

[VB.NET]
    Function SetEndOfFile(ByVal FileHandle As SafeFileHandle, ByVal EndOfFile As Int64)

Parameters

  • FileHandle - handle of the file previously opened using CreateFile(), OpenFile() or CreateNonCbFile() method
  • EndOfFile - New end of file (size of the file)

Return values

TRUE / true if the function succeeded or FALSE / false if the function failed.

Description

Use this method in your callback handler to change the size of the file without triggering further callbacks and avoiding the endless recursion.

See also

CreateFile     OpenFile    

Back to top