title: Incorrect range height error in Google Sheets Script
body: <p>Totally new to JS. The code looks at the YouTube ID "A2" and provides the title of the video and the total views. This works for one ID listed in "A2" but I cannot get it to work with a range.</p>
  
  <p>I have tried to adjust the ranges and used the row and column format. </p>
  
  <p>For example extending the cells to row 7 as you see below gives me this error "Incorrect range height, was 1 but should be 6 (line 7, file "Code")"</p>
  
  <pre><code>function getVideoInfo() {
    var sheet = SpreadsheetApp.getActiveSheet();
    var vid = sheet.getRange("A2:A7").getValue();
    var data = YouTube.Videos.list('snippet, statistics', {id: vid});
    var item = data.items[0];
    var info = [item.snippet.title, item.statistics.viewCount];
    sheet.getRange("B2:C7").setValues([info]);
  }
  </code></pre>
  
  <p>I also tried adjusting the data items to a number other than [0]</p>