Google Scripts - Copy existing spreadsheet and rename it -


i using google scripts. attempting to, upon form submission, copy , existing spreadsheet (not spreadsheet form submits to) , rename based upon cell in submission.

i assumed way identify spreadsheet copied id. here bit of code. both variables (newuserss , uuid) define properly.

  var newuserss = "1-bow_eikc-dt8px9ylwpjzttwjedyopxcassxq9ndvm";   var uuid = sheet.getsheetvalues(newline,2,1,1);   newuserss.copy(uuid); 

you can copy spreadsheet using retrieved spreadsheet using spreadsheet id.

the detail information of copy() here.

modified script :

var id = "1-bow_eikc-dt8px9ylwpjzttwjedyopxcassxq9ndvm"; var newuserss = spreadsheetapp.openbyid(id); var uuid = sheet.getsheetvalues(newline,2,1,1); newuserss.copy(uuid); 

if misunderstand question, i'm sorry.


Comments

Popular posts from this blog

ios - MKAnnotationView layer is not of expected type: MKLayer -

ZeroMQ on Windows, with Qt Creator -

unity3d - Unity SceneManager.LoadScene quits application -