How to arrange layer order in action script

guys i have tiled a background image using the code bellow:
*
import flash.display.BitmapData;
_root.createEmptyMovieClip(“tempMC”, 3, {_alpha:0});
var theLoader:MovieClipLoader = new MovieClipLoader();
var theListener:Object = new Object();
theLoader.addListener(theListener);
theListener.onLoadInit = function(mc:MovieClip) {
bitmapPic = new BitmapData(_root.tempMC._width, _root.tempMC._height);
bitmapPic.draw(mc);
_root.tempMC.removeMovieClip();
_root.createEmptyMovieClip(“picMC”, 4);

_root.picMC.beginBitmapFill(bitmapPic);
_root.picMC.lineTo(0,0);
_root.picMC.lineTo(0,140);
_root.picMC.lineTo(Stage.width,140);
_root.picMC.lineTo(Stage.width,0); 
    
_root.picMC.endFill(); 

};

theLoader.loadClip(“bg_header.gif”, _root.tempMC);*

and it was placed in the layer2.
at first layer (layer1) which is on the top of layer2,i put the codes bellow to display the icon of my website:

*import flash.display.BitmapData;
_root.createEmptyMovieClip(“tempMC3”,1, {_alpha:0});
var iconLoader:MovieClipLoader = new MovieClipLoader();
var iconListener:Object = new Object();
iconLoader.addListener(iconListener);
iconListener.onLoadInit = function(mc3:MovieClip) {
iconPic = new BitmapData(_root.tempMC3._width, _root.tempMC3._height);
iconPic.draw(mc3);
_root.tempMC3.removeMovieClip();
icon1.attachBitmap(iconPic, 2);
};

iconLoader.loadClip(“icon.gif”, _root.tempMC3);
*

but when it previewing, the icon appeared behind the repeat background, i don’t know why its happened, because i already put layer1(where the icon supposed be on the top) in the right place. please help me to figure it out. thanks.