Validation rule on delete action button in Datagrid

Good Day Mendix Expert, I have a Data Grid with search,new, edit, delete action button. I would like to created validation rule on the delete action button. It cannot delete data in the grid if the selected date is not greater than today, and only possible to do deletion for future data until 3pm on the currentdate time. I am hoping for your kind response.Thank you.  
1 answers

If this deletion-restriction is to be taken into account always for this entity, then the best place is on domain-level. Add a before-delete event in the ‘Event handlers’ tab.

If you only want to have this check in the datagrid, then you will need to create a microflow that does the validation and deletion (or not) and attach that microflow to your button.