title: Google AppScript - How to skip certain columns[INDEXes] when setting values from an ARRAY
body: <p>I am new to coding.</p>
  <p>I am trying to edit and set values from an entire row but want to skip certain columns, because there are formulas in it.</p>
  <p>In short: I want to / have to keep track of sing-in and sign-out times, which then will be calculated in the spreadsheet but shouldn't be overwritten by the array. Is there a way to skip every 3rd &quot;value&quot;/index (as these are the columns which have the formulas)?</p>
  <p>In fact I want to skip the columns: TOTAL, day1tot, day2tot, day3tot .... day14tot.</p>
  <pre><code>function editCustomerByID(id,customerInfo){
    const ss = SpreadsheetApp.getActiveSpreadsheet();
    const ws = ss.getSheetByName(&quot;DATA&quot;);
    const custIds = ws.getRange(2, 1, ws.getLastRow()-1, 1).getDisplayValues().map(r =&gt; r[0].toString().toLowerCase());
    const posIndex = custIds.indexOf(id.toString().toLowerCase());
    const rowNumber = posIndex === -1 ? 0 : posIndex +2; 
  
    Logger.log(customerInfo);
    ws.getRange(rowNumber, 2, 1, 8).setValues([[
                                                customerInfo.name, 
                                                customerInfo.total, 
                                                customerInfo.day1in, 
                                                customerInfo.day1out, 
                                                customerInfo.day1tot, 
                                                customerInfo.day2in,
                                                customerInfo.day2out, 
                                                customerInfo.day2tot   
  
                                              // UNTIL DAY 14     
                                              
                                           ]]);
  return true;
  </code></pre>