How prevent deleting of rows in a Child Table

Good day,
How can i prevent deleting of a row in a child table, I have used the code below but it is not working.

frm.get_field("items").grid.cannot_delete_rows = true;

@imbra try this:

$('[data-fieldname="items"]').find('.grid-delete-row').hide();  (this one to remove the button inside the item form)

if you gonna prevent all actions you can just select the child table as read only.

Thank you, this worked