How to lock the value in a view of a table

How to lock the view to prevent insert row or change value of a cell include the doc maker.
I just want to add a row to a table by a button.
I often mistakenly change the data in the view.