Hello ralphbrau,
Thank you for using Apple Support Communities! I understand that you are encountering an alert indicating that a file is in use when attempting to delete an Aperture library from an external drive connected to your Mac. I would be happy to help provide steps to take next.
Let's try restarting your Mac in macOS Recovery, then use Disk Utility to select and run First Aid on the external drive:
Repair a disk using Disk Utility on Mac - Apple Support
Test if your able to delete the Aperture library after. If not, we'll also want to make sure there are no background processes that could also be using this file:
How to use Activity Monitor on your Mac - Apple Support
Keep us posted on the results.
Cheers!