# AS newbie wanting help

**URL:** https://forum.kirupa.com/t/as-newbie-wanting-help/56308
**Category:** flash
**Created:** [July 2, 2004, 3:38pm UTC](https://forum.kirupa.com/t/as-newbie-wanting-help/56308 "2004-07-02T15:38:05Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Froggy](https://avatars.discourse-cdn.com/v4/letter/f/58956e/32.png) [@Froggy](https://forum.kirupa.com/u/Froggy)
#### Post date: [July 2, 2004, 3:38pm UTC](https://forum.kirupa.com/t/as-newbie-wanting-help/56308/1 "2004-07-02T15:38:05Z")

</div>

[font=Fixedsys][font=Arial]Hello fellow AS scripters!

I havea problem and I hope that u can help me out. The thing is that I’m going to have several buttons on my stage but I want them all to have the same animation or behavior when clicked on. So my question is how do I use a variable in an AS code session without strings or stuff like that.  
[/font]  
home.onRollOver = function(){  
buttonName = home;  
URL = “[http://www.google.com](http://www.google.com)”;  
};

home.onRollOut = function(){  
buttonName = “”;  
URL = “[http://www.google.com](http://www.google.com)”;  
};

[color=Red]buttonName[/color].onRelease = function(){  
getURL(URL, \_blank);  
};

[font=Arial]Thanks for helping me![/font]  
[/font]
