Confirm nessage before executing a custom action

Confirm nessage before executing a custom action

Hello,
do you know if it is possible to add a classic confirm message before executing a custom action?
Something like a javascritpt confirm "Are you sure?" (Yes or Not).

Thanks