Home » U++ Library support » U++ Core » File/Folder deleting, Recycle Bin and Read only files
File/Folder deleting, Recycle Bin and Read only files [message #24203] |
Tue, 05 January 2010 10:02  |
 |
koldo
Messages: 3432 Registered: August 2008
|
Senior Veteran |
|
|
Hello all
Presently we have this basic functions to delete files and folders:
bool FileDelete(const char *filename)
bool DirectoryDelete(const char *dirname)
They delete forever a file/folder if it is not read-only (and of course if it is available).
It would be great if they would manage as transparently as possible the Recycle Bin and the Read-Only files.
Some possible options would be:
1.- To add to this functions new parameters. For example:
bool FileDelete(const char *filename, bool recycleBin = false, bool delReadOnly = false)
bool DirectoryDelete(const char *dirname, bool recycleBin = false, bool delReadOnly = false)
or
enum DeleteFlags {DEL_FOREVER = 0, DEL_RECYCLE = 1, NOT_DEL_READONLY = 0, DEL_READONLY = 2};
bool FileDelete(const char *filename, int flags = 0)
bool DirectoryDelete(const char *dirname, int flags = 0)
2.- To add functions to handle this:
void SetDeleteToRecycleBin(bool val = false);
void SetDeleteReadOnly(bool val = false);
or
enum DeleteFlags {DEL_FOREVER = 0, DEL_RECYCLE = 1, NOT_DEL_READONLY = 0, DEL_READONLY = 2};
void SetDeleteFlags(bool val = false);
What do you think about it ?
Best regards
Koldo
Best regards
IƱaki
|
|
|
 |
|
File/Folder deleting, Recycle Bin and Read only files
By: koldo on Tue, 05 January 2010 10:02
|
 |
|
Re: File/Folder deleting, Recycle Bin and Read only files
|
 |
|
Re: File/Folder deleting, Recycle Bin and Read only files
By: koldo on Tue, 05 January 2010 15:11
|
 |
|
Re: File/Folder deleting, Recycle Bin and Read only files
By: mirek on Wed, 06 January 2010 07:49
|
 |
|
Re: File/Folder deleting, Recycle Bin and Read only files
By: koldo on Wed, 06 January 2010 11:51
|
 |
|
Re: File/Folder deleting, Recycle Bin and Read only files
By: mirek on Wed, 06 January 2010 21:59
|
 |
|
Re: File/Folder deleting, Recycle Bin and Read only files
By: koldo on Wed, 06 January 2010 23:10
|
Goto Forum:
Current Time: Wed Apr 30 10:44:12 CEST 2025
Total time taken to generate the page: 0.03996 seconds
|