Remembering a set value

Hey guys

I have a LCARS preset I’ve been working on for years which is finally nearing completion, but I was wondering if there was one final thing I could do with it.

It has 17 “themes”, 14 of which can be selected by the user and the other three are used for “alert statuses”. Theme15 is blue alert, Theme16 is yellow alert and Theme17 is red alert.

What I want to do is either add buttons to let the user select one of the three alert statuses and then if cancelled, go back to the previously set theme.

So if they have been using Theme5 and then select to go to “Red Alert” which is Theme17, when they hit “Cancel” it will go back to Theme5.

Thing is, the theme selection is via a list global - theme1,theme2,theme3,theme4,theme5 etc etc

The items change to the chosen theme by changing colour. Each theme has it’s own folder inside a colours folder and each theme has 22 colours - c1, c2, c3, c4 etc

Each items colour selection is set to a formula

$gv(colours/gv(theme)/c5)$

So scrolling through the ‘Theme’ list global just changes the colour global to the next theme and uses the colour for that theme

Because of this, when an red alert status is set, the theme list global will change to “theme17” and to cancel it, means setting the cancel button to select an option from the theme list global, like ‘Theme1’

So if the user had been using Theme5, then sets the red alert status, then cancels it…it will be set to Theme1, not the theme it had been on before the alert status

What I’m wondering is if the theme was set to Theme5, can that be remembered, only if the theme list is set to Theme15, Theme16 or Theme17, the previous setting of Theme5 is remembered and so when alert is cancelled, it returns the list global to Theme5

I’m thinking maybe flows might be the solution, but I know nothing about them

Sorry if this seems confusing, I’m not the best at explaining things and this is the best way I can explain it lol