# initObject with attachMovie()

**URL:** <https://forum.kirupa.com/t/initobject-with-attachmovie/194189>\
**Category:** flash\
**Created:** [July 21, 2006, 5:14am UTC](https://forum.kirupa.com/t/initobject-with-attachmovie/194189 "2006-07-21T05:14:49Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![riveroaks](https://avatars.discourse-cdn.com/v4/letter/r/90db22/32.png) [@riveroaks](https://forum.kirupa.com/u/riveroaks)\
**Post date:** [July 21, 2006, 5:14am UTC](https://forum.kirupa.com/t/initobject-with-attachmovie/194189/1 "2006-07-21T05:14:49Z")

</div>

I want to attach a preloader to the main stage of my site to load in external JPEGS and SWF’s and to do this I need to pass certain parameters to my preloader, such as the preloaders width and height. How do I make use of the initObject parameter for attachMovie()?  
I know I need to either define a constructor or somehow access the current movieClip’s constructor, but I have no want to create a custom class for my preloader movieclip, I just want to be able to get certain information when I attach the preloader. Do I really need to create a custom class that inherits from movieClip? If I do need to create a custom class, where do I place the constructor for this class?
