Utilities.FileRead Method

Applies to TestComplete 15.10, last modified on December 01, 2021
This method is obsolete. See the Remarks section below.


The Utilities.FileRead method reads the Count number of bytes from the file, whose handle is specified by the Handle parameter, to the Buffer. Note that you should use the file handle that is returned by the FileCreate or FileOpen function.


Utilities.FileRead(Handle, Buffer, Count)

Handle [in]    Required    Integer    
Buffer [out]    Required    Variant    
Count [in]    Required    Integer    
Result Integer

Applies To

The method is applied to the following object:


The method has the following parameters:


Specifies the handle of the file to be read.


Specifies the variable to which certain number of bytes will be read.


Specifies the number of bytes to be read from the specified file.

Result Value

The function returns the actual number of bytes read from the file. This number is less than or equal to Count.


Currently, this function works only in VBScript and DelphiScript scripts.

This method is obsolete. It is supported for backward compatibility only. To read from text and binary files, use various Read methods of the aqBinaryFile or aqTextFile object.

See Also

aqBinaryFile Object
aqTextFile Object
OpenBinaryFile Method
OpenTextFile Method
OpenBinaryFile Method
OpenTextFile Method
Cursor Property
Cursor Property

Highlight search results