Need a notification on deletion of a file/directory



Hi,

I am using CreateIoCompletionPort(), ReadDirectoryChangesW() and
GetQueuedCompletionStatus() APIs to get notification of file/folder
deletion. However, I need to determine whether the entity deleted is a
file or folder and accordingly perform an appropriate action.
I have noticed that ReadDirectoryChangesW() has a filter criteria
FILE_NOTIFY_CHANGE_DIR_NAME to get notification of folder
creation/deletion/rename. However AFAIK, this filter will not notify my
application about deletion of file. I am currently using
"FILE_NOTIFY_CHANGE_FILE_NAME | FILE_NOTIFY_CHANGE_DIR_NAME |
FILE_NOTIFY_CHANGE_ATTRIBUTES | FILE_NOTIFY_CHANGE_SIZE |
FILE_NOTIFY_CHANGE_LAST_WRITE | FILE_NOTIFY_CHANGE_CREATION |
FILE_NOTIFY_CHANGE_SECURITY" filter criteria.

Any help is highly regarded.

Thanks in advance,
- Uday

.