PC SOFT

WINDEVWEBDEV AND WINDEV MOBILE
ONLINE HELP

Home | Sign in | English UK
  • Operating mode in Windows Vista (and later)
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
Deletes a directory from a disk.
Remarks:
  • The user must have the rights to delete a directory.
  • A directory currently browsed by fDir or fListFile cannot be deleted.
WEBDEV - Server code Deletes a directory from the server disk. The Internet Guest account must have the rights to delete a directory.
WEBDEV - Server codePHPAjax
// Delete a directory
ResDelete = fRemoveDir("C:\MyDirectories\MyFiles")
Syntax
<Result> = fRemoveDir(<Directory to delete> [, <Deletion indicator>])
<Result>: Boolean
  • True if the directory was deleted,
  • False otherwise. To find out the error details, use ErrorInfo associated with the errMessage constant.
<Directory to delete>: Character string (with quotes)
Name and full (or relative) path of directory to delete. A UNC path can be used. The wildcard characters (*,?) are ignored. This directory name may (or may not) end with "\".
Versions 15 and later
WindowsLinux This parameter can be in Ansi or Unicode format.
New in version 15
WindowsLinux This parameter can be in Ansi or Unicode format.
WindowsLinux This parameter can be in Ansi or Unicode format.
<Deletion indicator>: Optional constant
frReadOnlyAlso deletes the read-only files. If this constant is not specified, the function will return False if read-only files must be deleted.
PHP This constant is not available.
frRecursiveThe contents of directory and sub-directories are also deleted. If this constant is not specified, the directory must be empty in order to be deleted.
frToRecycleBinSends the directory to the Windows bin instead of deleting it.
WEBDEV - Server codePHP This constant is not available.
<Deletion indicator> is empty by default. None of these options is selected.
Remarks
WEBDEV - Server code

Operating mode in Windows Vista (and later)

If this function does not operate properly in Windows Vista (and later), check whether the file or directory used is not in one of the system directories (Windows directory or "Program Files" directory).
Indeed, in Windows Vista (and later), with the UAC mechanism (User Account Control) enabled, you must have the administrator privileges to handle and/or modify the files or directories in the system directories (Windows directory or "Program Files" directory).
Programming tip: To handle and/or modify the files or directories without administrator privileges, you should:
  • avoid writing into the Windows directory or into the "Program Files" directory,
  • use the system directory corresponding to the application (returned by SysDir associated with the srCommonAppData constant).
Component : wd240std.dll
Minimum version required
  • Version 9
This page is also available for…
Comments
Exemplo Remover Diretorio Ftp
s_arquivo_endereco_remoto is string=SAI_Diretorio_Remoto+TABLE_remoto.COL_nome_arquivo
IF YesNo("Deseja Eliminar Arquivo servidor:["+s_arquivo_endereco_remoto) THEN
n_delela_arquivo_Ftp is int=FTPDeleteFile(n_conexao,s_arquivo_endereco_remoto)
arquivo_mostra_remoto()
END
De matos AMARILDO
08 Jan. 2016