Need help for managing scenes via scritp

Hi everybody.
I’m working on a quite simple script. It should be some kind of a interface where will be collected some functions for a file I’m working on.

One of the functions will be the one that allows you to go through the different scenes in the file and activate and deactivate different layers.
I found how to change layer visibility via Python, but don’t know how to change the active scene, so if someone of you could please let me know how to do this, it would be really nice.

Already thank you.

bpy.data.screens['Default'].scene = bpy.data.scenes['Scene']

There may be an easier/better way but I didn’t look too hard to find it.

Also in a context way:


bpy.context.screen.scene=bpy.data.scenes['Scene']

Really helpful.Thanks to both of you.