# Targetting problems

**URL:** <https://forum.kirupa.com/t/targetting-problems/65668>\
**Category:** Uncategorized\
**Created:** [September 28, 2004, 4:56pm UTC](https://forum.kirupa.com/t/targetting-problems/65668 "2004-09-28T16:56:55Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![afmaury](https://avatars.discourse-cdn.com/v4/letter/a/a587f6/32.png) [@afmaury](https://forum.kirupa.com/u/afmaury)\
**Post date:** [September 28, 2004, 4:56pm UTC](https://forum.kirupa.com/t/targetting-problems/65668/1 "2004-09-28T16:56:55Z")

</div>

I am trying to do a little rollover effect in my animation. The animation (call it today.swf) is loaded into another animation using XML. Inside of today.swf, I have 3 buttons. When you rollover each one, they are supposed to change the alpha property of a movie clip (clip1, clip2, and clip3 for the three buttons). It works fine within today.swf but not when it is loaded into the other movie. I am guessing this is some \_parent/.this stuff, but I can’t seem to make it work. Right now I have this on the buttons:

```auto
 
on (rollOver){
 setProperty(this.screen01, _alpha, "100");
}
on (rollOut){
 setProperty(this.screen01,_alpha,"0");
}

```

Any thoughts as to how to make this work?

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [September 29, 2004, 8:08am UTC](https://forum.kirupa.com/t/targetting-problems/65668/2 "2004-09-29T08:08:01Z")

</div>

you’d better use this

```php
on (rollOver){
 this.screen01._alpha= 100
}on (rollOut){
 this.screen01._alpha=0
}

```

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [September 30, 2004, 4:23pm UTC](https://forum.kirupa.com/t/targetting-problems/65668/3 "2004-09-30T16:23:57Z")

</div>

The problem is not that it will not change the alpha on rollover. The problem is in the targetting. When I use the code that I posted, it works just fine inside that particular movie. However, when I load this movie into a another, the alpha does not change at all.

Why would your code be better than my “setProperty” code?

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [October 1, 2004, 2:52pm UTC](https://forum.kirupa.com/t/targetting-problems/65668/4 "2004-10-01T14:52:35Z")

</div>

I’m using this code because this is the flash mx syntax, easier to target things, i made you a quick example using movieclips instead of buttons, and it should be working when loaded into another swf
