Preloading

i am doing a flash game and controlling everything through actionscript.
I have only one movie clip in first frame. All sounds and other movieclips that i control throgh actionscript have proper linkages and are exported in first frame. my question is does anybody know how do i add preloading to this???
what i have to include in my code to check if first frame ( where i am exporting everything ) is done loading or not???