Previous Document Next Document
CorelScriptTools.Kill

Function Kill(FileName As String) As Boolean

Member of CorelScriptTools

The Kill method deletes a file. This statement is the same as clicking File } Delete in the Windows Explorer or in My Computer in Windows.

Parameter
Description
FileName
String expression specifying the filename to delete. You can use wild cards (* and ?) if you want to delete a group of files. For example, script*.* deletes all of the files in the current folder beginning with script. Using script?.* deletes all of the files in the current folder that begin with script and are followed by only one more character.

  • An open file cannot be deleted.

The following code example deletes the file TEMP.OUT in the current folder:

KILL "temp.out" 

The following code example deletes the file TEMP.OUT in the C:\MyDocs folder:

KILL "C:\MyDocs\temp.out" 

Previous Document Next Document Back to Top

Copyright 2007 Corel Corporation. All rights reserved.