# \[AS2\] Variables Question

**URL:** <https://forum.kirupa.com/t/as2-variables-question/312819>\
**Category:** flash\
**Created:** [August 13, 2010, 10:00am UTC](https://forum.kirupa.com/t/as2-variables-question/312819 "2010-08-13T10:00:48Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Dr\_Diablo](https://avatars.discourse-cdn.com/v4/letter/d/e9a140/32.png) [@Dr\_Diablo](https://forum.kirupa.com/u/Dr_Diablo)\
**Post date:** [August 13, 2010, 10:00am UTC](https://forum.kirupa.com/t/as2-variables-question/312819/1 "2010-08-13T10:00:48Z")

</div>

[color=slategray]I have a simple question about Variables in AS2, i have a feeling the solution is pretty simple. What i exactly need is a variable that has a movieclip’s name stored inside it. I created a variable called **cardType** and stored the moviecip’s name inside it. Now when i declare the Tween you see below and assign it to the variable **cardType** (which should be replaced with the movieclip’s name), it does not work.

I’m not sure if i should be using variables for this, but if you get my idea please do let me know what would the correct approach be.

```php
var CardType;
CardType = LondonQuestions_mc.redCard_mc;

new Tween(cardType, "_alpha", Strong.easeOut, 0, 100, 2.5, true);

```

Thanks![/color]
