FILEDELETE

From iMacros
Jump to: navigation, search

Deletes the file specified by Name. If no directory is specified in Name the file is assumed to lie in the iMacros Downloads subdirectory (e.g. C:\Users\Me\iMacros\Downloads). You can also provide absolute paths to the file (e.g. C:\myData\lastDownloads.csv). This command can be used to delete an old extraction file to avoid appending extraction results.

Notes:

  • In the iMacros Browser and Internet Explorer, paths relative to the Downloads folder (e.g. Extracts\myTable.csv) are supported.
  • The file name can be surrounded by double quotes (if there is a space in the path, for instance). In this case, the backslashes have to be escaped by another backslash (as in "c:\\My Temp Files\\Temp.txt").


Syntax iMacros Browser IE Plug-in Firefox

FILEDELETE NAME=file_name

Example:

 FILEDELETE NAME=c:\output\mydata.csv

Parameters

  • Name
    Name of the file to be deleted.

Examples

Consider the case that a macro is extracting something from a webpage and saves it to the same file. Usually new data is appended to existing files. If you want the file to contain only the latest data, delete the file before saving.

See Also