The AddingItemToProcess event is raised when an item pair (current item and target item) is about to be added to a list of items to process.
The AddingItemToProcess event allows an application to examine an item pair, replace it or exclude the pair from the list of items to be processed by a method.
The following methods can raise the AddingItemToProcess event:
Method | Description |
---|---|
FileSystemItem.CopyTo() | Copies the item to another folder. |
FileSystemItem.MoveTo() | Moves the item to another folder. |
FileSystemItem.Create() | Creates the physical item. |
FileSystemItem.Delete() | Permanently deletes the physical item. |
AbstractFolder.CopyFilesTo() | Copies the folder's files to another folder. |
AbstractFolder.MoveFilesTo() | Moves the folder's files to another folder. |
AbstractFolder.CopyItemsTo() | Copies the folder's files and folders to another folder. |
AbstractFolder.MoveItemsTo() | Moves the folder's files and folders to another folder. |
The AddingItemToProcess event can be used to filter out potentially dangerous zipped items whose names contain relative path elements (like ..\..\) that, during an unzip operation can create or overwrite files outside of the base destination folder.