Description

Copies an operating system file to another operating system file.

Note: This is a Windows only function.

Syntax

result = UTILITY("COPYFILE",srcfile, destfile)

Parameters

The COPYFILE service has the following parameters.

ParameterDescription
srcfileSpecifies an operating system file or list of files. The file name includes the operating system drive and path.
destfileSpecifies the name of the destination table.
resultA boolean value. If true then the copy was successful otherwise an error occurred.

Note

If destfile exists and overwriteflag = 1, the file is copied and result = 1. The nonzero result does not indicate an error, but rather that destfile was overwritten.

See Also

CopyOSFile()

Name
BEEP Service
CHOOSECOLOR Service
CHOOSEDIR Service
CHOOSEFILE Service
CHOOSEFONT Service
CREATE Service
CURSOR Service
DESTROY Service
FLUSH Service
GET_EVENT Service
GETLOGICALDRIVES Service
MAKEDIR Service
OBJECTID Service
OBJECTLIST Service
PRINTSETUP Service
REMOVEDIR Service
RENAMEDIR Service
RENAMEFILE Service
RUNHELP Service
RUNWIN Service
TEXTRECT Service
WINCOUNT Service
HANDLE_BY_CURSOR Service
IUNKNOWN_RELEASE Service
LOAD_PICTURE Service
OBJECT_BY_CURSOR Service
PICTURE_PROPS Service

Example

/* copy C:\AUTOEXEC.BAT to C:\AUTOEXEC.SAV */
 
declare function Utility
retval = Utility("COPYFILE" , "C:\AUTOEXEC.BAT", "C:\AUTOEXEC.SAV")