Forum Discussion
AY-MPS
Aug 11, 2025Copper Contributor
Setting Default Worksheet using Office Scripts
I'm working on an office script for Excel that generates the file as I want it, but for some reason, the file automatically opens up to the last sheet in the lineup instead of the first. I've tried a...
JKPieterse
Aug 12, 2025Silver Contributor
As far as I know, all you would need in your script (at the end) are these two statements:
let sht = workbook.getFirstWorksheet();
sht.activate();