I am running a MacBook Pro Early 2015 13" on High Sierra 10.13.5, and keep getting the "X disk cannot be ejected because one or more programs might be using it" message, when apparently there is no program using that disk (not even Dropbox, Preview).
It happens sometimes when I try ejecting an external thunderbolt Drive, and always when ejecting any .sparseimages I only managed to "solve" this issue and be able to eject the disks by going into Terminal and "respringing" Finder:
However, I find this solution really inconvenient considering how often I use External Drives and disk images.
I would appreciate if anyone knows any other possible cause or solution, or if my solution is better than forcing the disk to eject.
Edit: After checking what processes were running, it seems there are "cloudd", "diskimage" and "QuickLookUIService" processes using a video file from the sparsedisk that are preventing me from ejecting the mounted sparseimage.