# Screen Start, Screen Open and Variable Change event sequence

**URL:** <https://community.thunkable.com/t/screen-start-screen-open-and-variable-change-event-sequence/1035606>\
**Category:** Questions about Thunkable X\
**Created:** [December 14, 2020, 11:42am UTC](https://community.thunkable.com/t/screen-start-screen-open-and-variable-change-event-sequence/1035606 "2020-12-14T11:42:25Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![drted](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/drted/32/92694_2.png) [@drted](https://community.thunkable.com/u/drted)\
**Post date:** [December 14, 2020, 11:42am UTC](https://community.thunkable.com/t/screen-start-screen-open-and-variable-change-event-sequence/1035606/1 "2020-12-14T11:42:26Z")

</div>

@domhnallohanlon, @wei,

Since the CLOUD variables are much easier to use than the Firebase GET and SAVE block, I wanted to see if the WHEN…INITILIZES OR CHANGES block could be used in place of the Firebase listener. I built an little app to track the screen START, screen OPEN, and WHEN…INITILIZES OR CHANGES for a CLOUD, STORED, and APP variable.

The cloud variable WHEN…INITILIZES OR CHANGES occurs on start up and when the variable changes (as I would hope). The STORED and APP variable WHEN…INITILIZES OR CHANGES occur not only when they change, but every time a screen opens. I’ve uploaded a screen capture in the zip file demonstrating the the out of my simple app [Thunkable](https://x.thunkable.com/copy/b05ec71b7e2251d9e11e0ed5eca4755f)

**First Time Load**

> Screen1StartBegin1607944674.356  
> MyApp1ChangeBegin1607944674.356  
> MyStored1ChangeBegin1607944674.356  
> Screen1OpenBegin1607944674.366  
> Screen1StartLoop11607944674.465  
> MyApp1ChangeLoop11607944674.473  
> MyStored1ChangeLoop11607944674.479  
> Screen1OpenLoop11607944674.485  
> Screen1StartLoop21607944674.577  
> MyApp1ChangeLoop21607944674.59  
> MyStored1ChangeLoop21607944674.595  
> Screen1OpenLoop21607944674.602  
> MyCloud1ChangeBegin1607944674.677  
> Screen1StartLoop31607944674.686  
> MyApp1ChangeLoop31607944674.697  
> MyStored1ChangeLoop31607944674.704  
> Screen1OpenLoop31607944674.709  
> MyCloud1ChangeLoop11607944674.784  
> Screen1StartComplete41607944674.795  
> MyApp1ChangeComplete41607944674.803  
> MyStored1ChangeComplete41607944674.81  
> Screen1OpenComplete41607944674.815  
> MyCloud1ChangeLoop21607944674.889  
> MyCloud1ChangeLoop31607944674.998  
> MyCloud1ChangeComplete41607944675.116

**Second Time Load (after switching to another screen)**

> Screen2StartBegin1607944703.126  
> MyApp2ChangeBegin1607944703.126  
> MyStored2ChangeBegin1607944703.126  
> Screen2StartLoop11607944703.235  
> MyApp2ChangeLoop11607944703.239  
> MyStored2ChangeLoop11607944703.246  
> Screen2StartLoop21607944703.341  
> MyApp2ChangeLoop21607944703.348  
> MyStored2ChangeLoop21607944703.355  
> Screen2StartLoop31607944703.447  
> MyApp2ChangeLoop31607944703.456  
> MyStored2ChangeLoop31607944703.464  
> Screen2OpenBegin1607944703.499  
> Screen2StartComplete41607944703.553  
> MyApp2ChangeComplete41607944703.562  
> MyStored2ChangeComplete41607944703.57  
> Screen2OpenLoop11607944703.606  
> Screen2OpenLoop21607944703.711  
> Screen2OpenLoop31607944703.816  
> Screen2OpenComplete41607944703.927

Notice that the Screen start event occurs every time the screen opens, not just the first time.

Additionally, the cloud variable change event only occurs when the app is first started, but the APP and STORED variable change events occur every time the screen opens. So in a multi screen app, the variable change event occurs every time there is a switch from one screen to the next

[ChangeDataSimple - Google Chrome 2020-12-14 03-13-46\_Trim.zip](https://community.thunkable.com/uploads/short-url/xE5K7FI11rkdJ2UFVFeA6gnRINB.zip) (3.5 MB)

If I add a Top Tab to encapsulate my 2 screens, the behavior changes again. Now the STORED and APP INITILIZES OR CHANGES occur when the screen first loads, and then only when the variables change.The cloud INITILIZES OR CHANGES events occur on both screen when the cloud variable is changed. Interestingly, it occurs twice on the starting screen.(_EDIT: Apparently the screen becase corrupted and has some sort of phantom event that I cannot delete causing the second change event_) The start events do not occur when switching between screens.  
[https://x.thunkable.com/copy/4d42fd9d42e7db3f65185ebf44d09ca7](https://x.thunkable.com/copy/4d42fd9d42e7db3f65185ebf44d09ca7)

here is a link to the long video of the top tab version demonstration.  
[https://drive.google.com/file/d/1Wc3jBLoNIBNGGsw9lDxWa4pNKjW0BET9/view?usp=sharing](https://drive.google.com/file/d/1Wc3jBLoNIBNGGsw9lDxWa4pNKjW0BET9/view?usp=sharing)

At the end of the day, it would be nice to have some sort of list or chart showing when these asynchronous events occur so we can manage our apps accordingly.

Thanks and Happy Thunking

---

<div class="post-metadata">

**Author:** ![muneer](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/muneer/32/75210_2.png) [@muneer](https://community.thunkable.com/u/muneer)\
**Post date:** [December 14, 2020, 12:32pm UTC](https://community.thunkable.com/t/screen-start-screen-open-and-variable-change-event-sequence/1035606/2 "2020-12-14T12:32:13Z")

</div>

I believe @eddie.rebehy had a go at the same subject a while ago arriving to similar results as yours @drted.

Firing events of screen start and open seems to take different behaviour when using the device keys than using navigation component keys.

---

<div class="post-metadata">

**Author:** ![ioannis](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/ioannis/32/146956_2.png) [@ioannis](https://community.thunkable.com/u/ioannis)\
**Post date:** [November 8, 2024, 12:19pm UTC](https://community.thunkable.com/t/screen-start-screen-open-and-variable-change-event-sequence/1035606/3 "2024-11-08T12:19:44Z")

</div>


