# Dynamically loading jpgs / manipulating them

**URL:** https://forum.kirupa.com/t/dynamically-loading-jpgs-manipulating-them/26645
**Category:** Uncategorized
**Created:** [July 25, 2003, 12:36am UTC](https://forum.kirupa.com/t/dynamically-loading-jpgs-manipulating-them/26645 "2003-07-25T00:36:14Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![julia](https://avatars.discourse-cdn.com/v4/letter/j/2bfe46/32.png) [@julia](https://forum.kirupa.com/u/julia)
#### Post date: [July 25, 2003, 12:36am UTC](https://forum.kirupa.com/t/dynamically-loading-jpgs-manipulating-them/26645/1 "2003-07-25T00:36:14Z")

</div>

Hello,

I’ve just learned how to dynamically load jpgs into flash but now i’d like to animate them. move them left to right, change the alpha, etc.

does anyone know how to do this?

thank you!

---

<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: [July 25, 2003, 12:50am UTC](https://forum.kirupa.com/t/dynamically-loading-jpgs-manipulating-them/26645/2 "2003-07-25T00:50:20Z")

</div>

you would just load the JPGs into a blank MC and then tell the MC what to do… right?

---

<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: [July 25, 2003, 12:51am UTC](https://forum.kirupa.com/t/dynamically-loading-jpgs-manipulating-them/26645/3 "2003-07-25T00:51:42Z")

</div>

Hi julia, you should take a look at the basic tutorials on this site. Here are some that might help.

[http://www.kirupa.com/developer/mx/motiontween.htm](http://www.kirupa.com/developer/mx/motiontween.htm)

[http://www.kirupa.com/developer/mx/basic\_animation.htm](http://www.kirupa.com/developer/mx/basic_animation.htm)

---

<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: [July 25, 2003, 1:03am UTC](https://forum.kirupa.com/t/dynamically-loading-jpgs-manipulating-them/26645/4 "2003-07-25T01:03:35Z")

</div>

hi!  
thanks for your responses. sorry, i’m very (VERY) new to actionscripting. i know how to tween and basic animation…just not sure how to do it to dynamically loaded jpgs…

i copied this script somewhere:

\_root.createEmptyMovieClip(“container”, 1);  
container.loadMovie(“images/image1.jpg”);  
container.\_x = container.\_y=0;

when i put this on my main timeline, i see my image loaded. when i try to put it into a separate mc (and then drag that mc onto the time line to tween it), nothing shows up…

thanks again!

---

<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: [July 25, 2003, 1:08am UTC](https://forum.kirupa.com/t/dynamically-loading-jpgs-manipulating-them/26645/5 "2003-07-25T01:08:38Z")

</div>

When you place that code into a MC, you need to change \_root to \_parent or this. So you script would look something like this now.

```auto
_parent.createEmptyMovieClip("container", 1);
container.loadMovie("images/image1.jpg");
container._x = container._y=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: [July 25, 2003, 1:15am UTC](https://forum.kirupa.com/t/dynamically-loading-jpgs-manipulating-them/26645/6 "2003-07-25T01:15:07Z")

</div>

hmm…for some reason, it’s still not working. i wonder what i’m doing wrong :-\

---

<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: [July 25, 2003, 5:06pm UTC](https://forum.kirupa.com/t/dynamically-loading-jpgs-manipulating-them/26645/7 "2003-07-25T17:06:04Z")

</div>

it’s usually helpful to post your .FLA so that we can all take a look at it and try to make helpful suggestions… could you attach it to your next post? i’d like to make sure you’re getting all the basics right before we make it overcomplicated 🙂

---

<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: [July 25, 2003, 6:14pm UTC](https://forum.kirupa.com/t/dynamically-loading-jpgs-manipulating-them/26645/8 "2003-07-25T18:14:17Z")

</div>

Hi there,

Thanks for your help. I actually found another way to do it:

[http://www.flashkit.com/board/showthread.php?threadid=345121&highlight=dynamic+load+jpg](http://www.flashkit.com/board/showthread.php?threadid=345121&highlight=dynamic+load+jpg)

Not sure if this is the best or most efficient way to do this, but it will work for now! thanks for your help.

Julia

---

<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: [July 25, 2003, 6:27pm UTC](https://forum.kirupa.com/t/dynamically-loading-jpgs-manipulating-them/26645/9 "2003-07-25T18:27:25Z")

</div>

hey, glad you found a way. good luck
