# Instantiation attempted on a non-constructor

**URL:** https://forum.kirupa.com/t/instantiation-attempted-on-a-non-constructor/248251
**Category:** flash
**Created:** [January 5, 2008, 8:35pm UTC](https://forum.kirupa.com/t/instantiation-attempted-on-a-non-constructor/248251 "2008-01-05T20:35:04Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Exodar](https://avatars.discourse-cdn.com/v4/letter/e/e79b87/32.png) [@Exodar](https://forum.kirupa.com/u/Exodar)
#### Post date: [January 5, 2008, 8:35pm UTC](https://forum.kirupa.com/t/instantiation-attempted-on-a-non-constructor/248251/1 "2008-01-05T20:35:04Z")

</div>

```auto
package
{
    import flash.display.Bitmap;
    import flash.display.Sprite;
    import flash.geom.ColorTransform;
    
    public class Color extends Sprite
    {
        public var Picture:Class;
        
        public function Color()
        {
            transformColor();
        }
        
        private function transformColor():void
        {
            var pic:Bitmap = new Picture();
            addChild(pic);
            
            pic.transform.colorTransform = new ColorTransform(-1, -1, -1, 1, 
                                                              255, 255, 255, 0);
        }
    }
}

```

Using this as the document class for a separate fla file, i’m getting this error when the movie is exported:

\*\*TypeError: Error #1007: Instantiation attempted on a non-constructor.

\*\*why is this?
