RE: global variable not working
You create a global variable by creating it outside the scope of functions hence the top of the script. However if Messenger isn't signed in then the object Messenger.MyName doesn't exist and will cause the script to stop and never start when they sign back in.
That is why my code I create the global variable outside of the scope but declare it as a string instead of Messenger.MyName.
Also the script wont run on Initialize because it catches an error if the user isn't signed in. And when they are signed in it will recall Initialize function.
This is a much better practise. Or instead of try() you can use if (Messenger.MyStatus > 2)
|