What does HRESULT 0xC0AAB10A (IMAPI_E_DIR_NOT_EMPTY) mean?

 
Previous Next
IMAPI_E_NOT_DIR IMAPI_E_NOT_IN_FILE_SYSTEM

IMAPI_E_DIR_NOT_EMPTY

IMAPI_E_DIR_NOT_EMPTY means the target IFsiDirectoryItem still contains child items when an operation requires an empty directory. IMAPI exposes separate Remove and RemoveTree semantics: removing a directory item is not the same as recursively removing its subtree.

Enumerate children before deleting or replacing the directory

  • Read the directory item collection or child count and record the names still present.
  • Confirm whether the caller intended a single-item removal or recursive tree removal.
  • Keep imported and newly added children visible; a previous-session import can populate paths the current build code did not explicitly create.

Blindly retrying the same removal does not change the hierarchy. If recursive deletion is intended, use the tree operation deliberately and understand that the content is removed from the image model. If recursion is not intended, the remaining children identify the application logic error. This distinction is safer than automatically clearing every nonempty directory just to make image generation proceed.

IFsiDirectoryItem · Remove · RemoveTree


Looking for a different code? Search another status or error code.