Rename Procedure

Applies to TestComplete 15.47, last modified on January 20, 2023

The Rename procedure changes the name of the desired file.

Declaration

Rename(FileVarNewName) Parameters
FileVar [in] Required Variant
NewName [in] Required String
Result     None  

Description

Changes the name of file associated with the file variable by calling the AssignFile procedure. The specified file must be closed before it is renamed.

Parameters

The procedure has the following parameters:

FileVar

Specifies the file variable, which is associated with the desired file by calling the AssignFile procedure.

NewName

Specifies the variable that holds the new file name.

Remarks

After executing the Rename procedure, all of the operations work with the file that has the new name.

See Also

DelphiScript - List of Supported Routines and Variables
AssignFile
Erase

Highlight search results