revDeleteFolder |
Type | command |
Dictionary | LCS |
Library | LiveCode Script |
Syntax | revDeleteFolder <folderToDelete>
|
Summary | Removes a folder and all its contents.
|
Introduced | 1.1.1 |
OS | mac, windows, linux |
Platforms | desktop, server |
Parameters | Name | Type | Description |
---|
folderToDelete | | The folderToDelete specifies the name and location of the folder. If you
specify a name but not a location, LiveCode assumes the folder is in the
defaultFolder.
|
|
Example | revDeleteFolder "/data/Backup Folder"
revDeleteFolder myTempFolder
|
Values | |
Related | Property: defaultFolder
Message: startup, openBackground, preOpenStack, openStack, preOpenCard
Library: Common library, library
Glossary: application, standalone application, file, shell, subfolder, platform, command, Windows, main stack, OS X, AppleScript, group, Unix, Mac OS, folder, message, handler
Control Structure: function
Function: folders, result
Command: revCopyFolder, create folder, answer folder, delete file, revMoveFolder
Object: stack
|
Description | Use the revDeleteFolder function to remove a folder from the disk.
The revDeleteFolder command removes the entire folder, including
all files, subfolders, and their contents.
Warning: This command can be used to rename or move files
and folders your stack did not create. Of course, a stack
should not rename or move files and folders it didn't
create without obtaining explicit confirmation from the user.
Note: This command can not delete the defaultFolder and will
fail if the folderToDelete is or contains the defaultFolder.
Note: When included in a standalone application, the
Common library is implemented as a hidden group and made
available when the group receives its first openBackground
message. During the first part of the application's
startup process, before this message is sent, the
revDeleteFolder command is not yet available. This may affect
attempts to use this command in startup, preOpenStack,
openStack, or preOpenCard handlers in the
main stack. Once the application has finished starting up,
the library is available and the revDeleteFolder command
can be used in any handler.
|