Guest User

Untitled

a guest
May 24th, 2018
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.67 KB | None | 0 0
  1. function ss_sheet_copy-name() {
  2.  
  3. /****************************************************************
  4. スプレッドシートのシートのコピーと名前変更
  5. ****************************************************************/
  6.  
  7. // 現在のスプレッドシートの取得
  8. var ss_active_all = SpreadsheetApp.getActiveSpreadsheet();
  9.  
  10. // 書出シートの作成(temp_listのコピー作成)
  11. var ss_sheet_temp = ss_active_all.getSheetByName("temp_sheet"); //temp_sheetというシートがある前提
  12. var ss_sheet_copy = ss_sheet_temp.copyTo(ss_active_all);
  13.  
  14. // コピーしたシートの名前変更
  15. ss_sheet_copy.setName("**************"); // 自由に命名
  16.  
  17. }
Add Comment
Please, Sign In to add comment