How to save a grid data in the spreadsheet

PROTOTIPOmuestra.ods (28.8 KB)

The program works like this: we enter a data within the search engine, any data is selected, the values are returned in the corresponding boxes, and when we select “ADD” it inserts the data in the second grid, after that I need that with a button save the data of that second grid to the spreadsheet