Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Using Google appscript to refresh tables pasted in from Google sheets into Google slides

This question here has as succinct solution for updating Google Sheets charts linked to Google slides.

function onOpen() {
  var ui = SlidesApp.getUi();
  ui.createMenu('Custom Menu')
  .addItem('Batch Update Charts', 'batchUpdate')
  .addToUi();
}

function batchUpdate(){

  var gotSlides = SlidesApp.getActivePresentation().getSlides();

  for (var i = 0; i < gotSlides.length; i++) {
    var slide = gotSlides[i];
    var sheetsCharts = slide.getSheetsCharts();
    for (var k = 0; k < sheetsCharts.length; k++) {
      var shChart = sheetsCharts[k];
      shChart.refresh();
    }
  }
}

I wish to do the same thing but with a table pasted into Google Slides from Google Sheets. I can't see how this would look in the AppScript API for Google Slides. Can someone point out a way forward?

like image 687
goose Avatar asked Nov 21 '25 13:11

goose


1 Answers

Latest update: There is now an option in Slides's Tools drop-down menu to see all Linked Objects; the menu that appears has the option at the bottom to "Update all".

enter image description here enter image description here

like image 195
Aleister Tanek Javas Mraz Avatar answered Nov 23 '25 06:11

Aleister Tanek Javas Mraz



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!