Destroy with OnClick

Hello People, im new in Unity and maybe its a silly question.I’ve read other threads but i dont find it.
So i have a Button and On click must Destroy Enemy Object. The Script that the Button hat is :

public GameObject Enemy;
public void Matar()
{
Destroy(Enemy.gameObject);
}

}

It does anything when pressed. Enemy is in the Scene and Script is attached to the Button.

Thanks for your Answers!!

have you set “Matar” as the function to be called by the OnClick event, or just added the script to the same gameobject?

I set the function OnClick Matar
i dont know if i have to to something to the Enemy object

Problem solved! i didn’t attached the Enemy Object to the script!! thanks anyway!!!