Simple Script Question

I downloaded the example for the following site:
[COLOR=#336699]http://www.webzo.org/tutorials/flash…-slideshow.php[/COLOR]
It allows you dow add images to the .xml file and then it show the images in a flash. Basically a slide show, but I have one problem the images have to be preset to the following side of the document its self. So I added the following code so the images can re size:

Can This be converted over to ActionScript 2?

import flash.display.StageScaleMode;
import flash.display.StageAlign;
import flash.events.Event;

stage.scaleMode = StageScaleMode.NO_SCALE;
stage.align = StageAlign.TOP_LEFT;
stage.addEventListener (Event.RESIZE, resizeHandler);

// initialize sizing
resizeHandler (null);

function resizeHandler (event:Event):void {
var sw:Number = stage.stageWidth;
var sh:Number = stage.stageHeight;
picture_mc.width = sw;
picture_mc.height = sh-header_mc.height;
}
function randomImage() {
if (loaded == filesize) {
var ran = Math.round(Math.random() * (totalImages - 1));
picture_mc.loadMovie(imageFileName[ran], 1);
pause();
}
}