0
votes

I have very limited knowledge of google sheets and would appreciate any and all help.

I have created a google sheet with multiple sheets. I would like to have the names that are typed in the cells for student names name the following sheets.

Thank you.

Here is a link to the google sheet: https://docs.google.com/spreadsheets/d/1pOOwg5HLGXVg9XynJBGcVWjqnCV6xZSmMX38hZZgmvg/edit?usp=sharing

1

1 Answers

0
votes

How about following script?

function sample() {
  var ss = SpreadsheetApp.getActiveSpreadsheet();
  var summarysheet = ss.getSheetByName('Put name of summary sheet name');
  var names = summarysheet.getRange('a4:a38').getValues();
  names.forEach(function(e, i){
    ss.getSheets()[i + 1].setName(e);
  });
}

I thought that it is very important the correspondence of names of summary sheet and each sheet. So conditions to use this sample script is as follows.

  1. If you change the arrangement of sheets, the correspondence of names of summary sheet and each sheet cannot be done.

  2. How do you think about the correspondence of names of summary sheet and number of sheets? Now, the number of sheets is 35 + (a summary sheet). This is same to (names of summary sheet) + 1. If you want to insert new sheets using script, please tell me.

  3. It cannot make sheets with same sheet name. So if there are same student names, it is necessary to change a bit.

If you have a script you made for your question, can I ask you about it?