# Change Variables on Exit in AS3?

**URL:** <https://forum.kirupa.com/t/change-variables-on-exit-in-as3/324166>\
**Category:** Uncategorized\
**Created:** [August 5, 2011, 6:28pm UTC](https://forum.kirupa.com/t/change-variables-on-exit-in-as3/324166 "2011-08-05T18:28:40Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Scheisse](https://avatars.discourse-cdn.com/v4/letter/s/839c29/32.png) [@Scheisse](https://forum.kirupa.com/u/Scheisse)\
**Post date:** [August 5, 2011, 6:28pm UTC](https://forum.kirupa.com/t/change-variables-on-exit-in-as3/324166/1 "2011-08-05T18:28:40Z")

</div>

Hello I am doing some server communication in AS3 / PHP / MySQL and I was wondering if there was a way to change a variable just before the user closes Flash?

Example: User closes browser or tab and Flash updates a variable before it closes the player.

I would like to be able to send the message to the server so that it knows that the user quit as it happens.

Thanks.
