# How to get a data from other frame ?i

**URL:** <https://forum.kirupa.com/t/how-to-get-a-data-from-other-frame-i/326771>\
**Category:** Uncategorized\
**Created:** [January 11, 2012, 11:48am UTC](https://forum.kirupa.com/t/how-to-get-a-data-from-other-frame-i/326771 "2012-01-11T11:48:17Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![raphaelle](https://avatars.discourse-cdn.com/v4/letter/r/7bcc69/32.png) [@raphaelle](https://forum.kirupa.com/u/raphaelle)\
**Post date:** [January 11, 2012, 11:48am UTC](https://forum.kirupa.com/t/how-to-get-a-data-from-other-frame-i/326771/1 "2012-01-11T11:48:17Z")

</div>

hi

im working on a side scroller game, and im in a middle of shared objects

now my problem is i cant have the data from other frame this is my codes  
(i know its wrong but idk what to do)

var heroLife:Number = 10;

private function framehandler(e:Event):void  
{  
if(currentFrame == 1)  
{  
mylife.text = String(heroLife);  
}

if(currentFrame == 2)  
{  
charLife.text = String(mylife.text);  
}

}

there is an error, it just mean that it cant find charLife.text bcoz its from other frame

now i want to know if it is posible to do this.

thank you guys,

cheers  
raphaelle
