Are you using IF statements on the variables? One better solution may be to use custom variables and set them to a specific value so that onPageShow, it’s looking to see if the variable is “visited”.
onPageShow <the action you’re using to change the state> IF This page is complete.
I’m not a fan of delays, as it could impact UX if the button is loaded initially in one state, then suddenly is in a different state moments later.
Also, when posting samples, the zipped development file needs to be uploaded so we can see how you configured actions.