title: Google Apps Script "cannot find function" offset in object
body: <p>Can any help with the following issue???  Pretty new to app script / javascript and would appreciate any help or guidance to figure out..</p>
  
  <p>TypeError: Cannot find function offset in object Timestamp, (then continues listing the column headings in the red warning banner.</p>
  
  <pre><code>function uiSendLogEmail() {
  var ss = SpreadsheetApp.getActiveSpreadsheet();
  var sheet = ss.getActiveSheet();
  var data = sheet.getDataRange().getValues();
    data = data.offset(1,0,data.getNumRows())-1;
  
  
  // For Loop
  
  for ( var i = 0; i &lt; data.length; i++ ) {
  var row = data[i];
  var approved = row[5];
  var sentEmail = row[6];
  var snapshot = row[3];
  
  //if stmt in For Loop
  if ( approved != "Yes" ) {              
    data[i][5] = "Yes";
    data.getDataRange().setValues(data);
        }// if stmt end curly 
  else if ( approved == "Yes" &amp;&amp; sentEmail != "Yes" ) {
    data[i][6] = "Yes";
    data.getDataRange().setValues(data);
    GmailApp.sendEmail("email@email.com", "subject", "body" + "whatever " + snapshot);
  }//else if end curly
  else {
  return;
  }//else stmt end curly
  
  }// for loop end curly
  
  
   }
  </code></pre>