jeudi 27 mars 2014

Copy a range from one sheet to another in google sheet


Vote count:

0




I ave been trying to copy a range from one google sheet to another without success. I have tried all the answers that I have come accross but they were al fruitless for me. Everything in the script work apart from the content or ell does not get copied.


Any help or guidance will be very much appreciated. Here is the code that I am using:


function copyCell() {


var ss = SpreadsheetApp.getActiveSpreadsheet();


var source = ss.getSheetByName("City");


var destination = ss.getSheetByName("Boost");


var source_range = source.getRange("A17").getValue();


ss.setActiveSheet(ss.getSheets()[2]);


destination.insertRowAfter("3");


var destination_range = destination.getRange("A4")


destination_range.setValue(source_range);


Browser.msgBox("The value has been added",Browser.Buttons.OK)


}



asked 14 secs ago






Aucun commentaire:

Enregistrer un commentaire