Is there a way to determine the Material Element Id that has been hit?

Thankyou for your reply I’ll try this tomorrow and see if it works for me.