# AS question : defining whats in a varible

**URL:** https://forum.kirupa.com/t/as-question-defining-whats-in-a-varible/130796
**Category:** Uncategorized
**Created:** [December 8, 2004, 6:25pm UTC](https://forum.kirupa.com/t/as-question-defining-whats-in-a-varible/130796 "2004-12-08T18:25:18Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Casenote](https://avatars.discourse-cdn.com/v4/letter/c/82dd89/32.png) [@Casenote](https://forum.kirupa.com/u/Casenote)
#### Post date: [December 8, 2004, 6:25pm UTC](https://forum.kirupa.com/t/as-question-defining-whats-in-a-varible/130796/1 "2004-12-08T18:25:18Z")

</div>

In my movie I have 4 MC’s named: quan1, quan2, ect…

I have this on my main timeline.

```auto

#include "lmc_tween.as"
_global.sectionTimeline=this;
selectedQuan = quan1;
selectedQuan.colorTo(0x719155, 1, "easeOutBack");
stop();

```

and I have this on the quan1 movie clip.

```auto

on (rollOver) {
	this.colorTo(0x719155, 1, "easeOutBack");
	this.scaleTo(115, 1, "easeOutBack");
}

on (rollOut) {
		if (sectionTimeline.selectedQuan=quan1) {
			this.scaleTo(100, 1, "easeOutBack");
		}
			else{
				this.colorTo(0x2C455C, 1, "easeOutBack");
				this.scaleTo(100, 1, "easeOutBack");
			}
}

```

Now when the movie loads it changes quan1 to a green color  
But when I rollover it goes to the else statement…even though selectedQuan is set to quan1.

I debugged it and it shows the varible selectedQuan as nothing.

Anyone have any ideas?

Case ;(
