I am taking my first steps in any sort of coding language, been proficient with Excel/Sheets for a while and looking to start automating a few small things to make mine and my teams' life a little easier. Currently I have successfully written it to copy my Template sheet and rename the template to the selected name from a dropdown menu on a tab called "Create Sheet" (Cell J21) but I am struggling with getting it to rename cell B1 on the new sheet to the selected name as well, here is what I have for copying the template. I tried a few things I found through Google and YouTube last night for also writing to B1 on the copies of Template but was unsuccessful.
function CreateSheet() {
var app = SpreadsheetApp;
var ss = app.getActiveSpreadsheet();
var TemplateSheet = ss.getSheetByName('Template');
var newSheet = TemplateSheet.copyTo(ss);
var SheetName = ss.getRange("J21").getValue();
// Makes the new sheet the active sheet and renames it to the name in cell 'Create Sheet'J21 //
ss.setActiveSheet(newSheet);
ss.renameActiveSheet(SheetName);
// Renames cell B1 on the new sheet to the name in 'Create Sheet'J21 //
// ** this is where I am needing help **

