title: Google Slides: newly inserted table not found
body: <p>I´m wondering what is going on. I have two functions which both are working good when called one after one: </p>
  
  <pre><code>function createTable() {
    var slidesPage = SlidesApp.openById('1QWRV4eQzGNNBz4SkR3WPurTL3O60oGYxQpBu63KrUoI').getSlides()[0];
  
    var table = slidesPage.insertTable(7, 4);
  }
  
  
  function changeColumnWidth() {
  
    var slidesPage = SlidesApp.openById('1QWRV4eQzGNNBz4SkR3WPurTL3O60oGYxQpBu63KrUoI').getSlides()[0];
  
    var tableId = slidesPage.getTables()[0].getObjectId();
  
    var requests = [{
      updateTableColumnProperties: {
        objectId: tableId,
        "columnIndices": [ 1, 3],
        "tableColumnProperties": {
          "columnWidth": {
            "magnitude": 80,
            "unit": "PT"
           }
         },
        "fields": "columnWidth"
       }
     }];
  
    var createSlideResponse = Slides.Presentations.batchUpdate({
      requests: requests
    }, '1QWRV4eQzGNNBz4SkR3WPurTL3O60oGYxQpBu63KrUoI');
  
  }
  </code></pre>
  
  <p>But trying to combine these two functions like:</p>
  
  <pre><code>function combined() {
     createTable();
     changeColumnWidth();
  }
  </code></pre>
  
  <p>I´m getting Error:</p>
  
  <blockquote>
    <p>Invalid requests[0].updateTableColumnProperties: The object (SLIDES_API456304911_0) could not be found.</p>
  </blockquote>
  
  <p>Wondering if the <code>insertTable</code> method is asynchronous and therefore the created table is not ready?
  Thanks for any help. </p>