title: What did I do wrong on this script? It says "Cannot find function createMenu in object Spreadsheet."
body: <p>What did I do wrong?</p>
  
  <pre><code>function onInstall() {
      onOpen();
  function onOpen(e) {
      SpreadsheetApp.getActive()
          .createMenu('Sentrix Messaging')
          .addItem('Index', 'new mail')
          .addItem('Compose', 'Write mail')
          .addToUi();
      Browser.msgBox('Welcome to Sentrix Email');
      ShowSidebar();
  }
  
  function showSidebar() {
      var html = HtmlService.createTemplateFromFile("Inbox")
          .evaluate()
          .setTitle("Email");
      SpreadsheetApp.getUi().showSidebar(html);
  }
  }
  </code></pre>
  
  <p>It says</p>
  
  <blockquote>
    <p>Cannot find function createMenu in object Spreadsheet</p>
  </blockquote>