# Loading movieclips from library

**URL:** <https://forum.kirupa.com/t/loading-movieclips-from-library/316863>\
**Category:** Uncategorized\
**Created:** [December 4, 2010, 5:14pm UTC](https://forum.kirupa.com/t/loading-movieclips-from-library/316863 "2010-12-04T17:14:04Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![siryami](https://avatars.discourse-cdn.com/v4/letter/s/e19adc/32.png) [@siryami](https://forum.kirupa.com/u/siryami)\
**Post date:** [December 4, 2010, 5:14pm UTC](https://forum.kirupa.com/t/loading-movieclips-from-library/316863/1 "2010-12-04T17:14:04Z")

</div>

## Hello, i am trying to load movieclips from the library using an array. I have manage to load a single movieclip using

var myArray:Array=[];

myArray[1]=imagex1;

## var mc:MovieClip = new myArray[1]; addChild(mc);

but now I’ve tried using a loop by doing

* * *

var myArray:Array=[];

for(var i:uint = 0; i \< 8; i++){  
myArray\*=“imagex”+i;

```
var mc:MovieClip = new myArray*;
addChild(mc);

```

## }

and i get the error:  
TypeError: Error #1007: Instantiation attempted on a non-constructor.  
at usethis4\_fla::MainTimeline/frame1()

I new at this so i don’t really understand what that means, can someone help with this? Thanks
