# duplicateMovieClip not a function

**URL:** <https://forum.kirupa.com/t/duplicatemovieclip-not-a-function/258057>\
**Category:** flash\
**Created:** [April 20, 2008, 12:45pm UTC](https://forum.kirupa.com/t/duplicatemovieclip-not-a-function/258057 "2008-04-20T12:45:40Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ymaod](https://avatars.discourse-cdn.com/v4/letter/y/94ad74/32.png) [@ymaod](https://forum.kirupa.com/u/ymaod)\
**Post date:** [April 20, 2008, 12:45pm UTC](https://forum.kirupa.com/t/duplicatemovieclip-not-a-function/258057/1 "2008-04-20T12:45:40Z")

</div>

Hi,

I’m creating a 5x5 matrix with 25 movieclips of w:22px h:22px.  
the first movieclip wich is called c1\_mc and is part of a movieclip called grid.

I’m using following code to make the complete grid:

```auto

var lineWidth : Number = 22;
var columnHeight : Number = 0;
var mc : MovieClip;
for (var i : Number = 2; i <= 25 ; i++) {
     mc = c1_mc.duplicateMovieClip("c" + i + "_mc",i);
     lineWidth += 22;
     if (lineWidth >= mc.parent.width) {
         columnHeight += 22;
         lineWidth = 0;
         mc.move(mc.x + lineWidth,mc.y+columnHeight);
     } else {
         mc.move(mc.x + lineWidth,mc.y+columnHeight);
     }
}

```

But i’m getting following error:  
Error #1006: duplicateMovieClip is not a function.

What could be the problem?

Best regards
