Converting .xls to google spreadsheet in google apps script

This is now possible using the Advanced Drive service:

https://developers.google.com/apps-script/advanced/drive

When using Drive.Files.insert, simply set the optional parameter “convert” to “true”.

var file = {
    title: 'Converted Spreadsheet'
  };
  file = Drive.Files.insert(file, xlsxBlob, {
    convert: true
  });

This was also obtained from the above given issue

Leave a Comment