Hi Benjamin,
Am not 100% sure I know what you are trying to do, but thank you for sharing the script. :)
The Indexed IF is looking at the bom component, so please pass that up as your value in column G.
Also, please include the delete action in your Indexed IF, so you're only deleting if you find a match. Thus I would try including rows 15-18 inside the IF statement.

Also please run in debug mode to double check that the logic is doing what you intended.
Best Regards,
Sigrid
------------------------------
Sigrid Kok
Precisely Software Inc.
------------------------------