# Loader Component & MC Button

**URL:** https://forum.kirupa.com/t/loader-component-mc-button/185961
**Category:** flash
**Created:** [April 18, 2006, 2:35am UTC](https://forum.kirupa.com/t/loader-component-mc-button/185961 "2006-04-18T02:35:42Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Red](https://avatars.discourse-cdn.com/v4/letter/r/59ef9b/32.png) [@Red](https://forum.kirupa.com/u/Red)
#### Post date: [April 18, 2006, 2:35am UTC](https://forum.kirupa.com/t/loader-component-mc-button/185961/1 "2006-04-18T02:35:42Z")

</div>

Hi There,

I am currently setting up a simple photo gallery using the Loader component with Flash 8, it works fine if I run the code from a button but if I try to use the code on a MovieClip nothing happens. I was hoping there was a really easy solution to this that I must be overlooking. If someone could look at my code and give me any pointers that would be awesome.

Here it goes:

[COLOR=navy]on (rollOver) {  
this.gotoAndPlay(“mouse\_over”);  
}[/COLOR]

[COLOR=navy] on (rollOut) {  
this.gotoAndPlay(“mouse\_out”);  
}[/COLOR]

[COLOR=navy]on (release) {  
myLoader.contentPath = “Images/lrg/TTC-Hillcrest02.jpg”;  
}[/COLOR]

Thanks again for any help  
Red

---

<div class="post-metadata">

### Author: ![Red](https://avatars.discourse-cdn.com/v4/letter/r/59ef9b/32.png) [@Red](https://forum.kirupa.com/u/Red)
#### Post date: [April 18, 2006, 5:08pm UTC](https://forum.kirupa.com/t/loader-component-mc-button/185961/2 "2006-04-18T17:08:42Z")

</div>

Boy do I feel stupid - I knew it was something simple - I needed to point to the root timeline where myLoader is:

[COLOR=navy]on (release) {  
[COLOR=red]\_root.[/COLOR]myLoader.contentPath = “Images/lrg/TTC-Hillcrest02.jpg”;  
}[/COLOR]
