Assuming that your script gives you what you expect
All sheets :
function myFunction() {
var ss = SpreadsheetApp.getActiveSpreadsheet()
ss.getSheets().forEach(function (sheet){
var cell = sheet.getRange("B4");
var refresh = parseInt(cell.getValue().toString());
var increment = refresh + 1;
cell.setValue(increment);
})
}
All sheets except a list (Edit by Cooper)
function myFunction() {
var ss = SpreadsheetApp.getActiveSpreadsheet();
const exclA = ['Sheet1','Sheet2'];//excluded sheets
ss.getSheets().filter(sh => {!~exclA.indexOf(sh.getName())}).forEach(function (sheet){
var cell = sheet.getRange("B4");
var refresh = parseInt(cell.getValue().toString());
var increment = refresh + 1;
cell.setValue(increment);
})
}
bitwise not