 |
RemoveDirectory Add comment W32 Constants Translate this page |
 |
 |
|
The RemoveDirectory function deletes an existing empty directory. To recursively delete files and subdirectories in a directory, use the SHFileOperation function. |
 |
 |
| Code examples: |
 |
|
|
 |
 |
| Declaration: |
 |
 |
BOOL RemoveDirectory(
LPCTSTR lpPathName // directory name
);
|
 |
 |
 |
| FoxPro declaration: |
 |
 |
DECLARE INTEGER RemoveDirectory IN kernel32;
STRING lpPathName
|
 |
 |
 |
| Parameters: |
 |
lpPathName
[in] Pointer to a null-terminated string that specifies the path of the directory to be removed. The path must specify an empty directory, and the calling process must have delete access to the directory |
 |
 |
| Return value: |
 |
| If the function succeeds, the return value is nonzero |
 |
 |
| Usage: |
 |
cPathName = "C:\Temp\aa"
? RemoveDirectory(cPathName)
|
 |
 |
| My comment: |
 |
To recursively delete the files in a directory, use the SHFileOperation function.
See also: RemoveDirectoryTransacted |
 |
 |
| Word Index links for the RemoveDirectory : |
 |
|
|
 |
 |
| Translate this page: |
 |
|
 |
 |
| • |
 |
| Created: | 2001-07-12 12:00:00 | | Modified: | 2010-05-24 12:13:44 | Visited in last 7 days: 17 |