Help with scrollable image expressions please

Being new to AS, I am trying to familiarise myself by undertaking a personal project based on free AS tutorial describing how to make a horizontal mouse driven scroller in AS 2.0. For me, a learn by copying and modifying exercise. But I do not know how to express the code for my images.

At the moment all the images are stacked upon each other from the Test Movie so there are code faults in the AS. All image clips in the fla Library are a standard 385 pixels high but of varying width. I need code which allows each image to appear at its own width (100%), with a 50 pixel separation between each item. I want to use the code to replace the AS code below and would appreciate any help that can be offered.

This tutorial code below is for a standard image height and width, each image butting up to its neighbor.

Can anyone replace the image component code for script which achieves my objectives above please.

images.this.createEmptyMovieClip(“container”,1);
var imagesNumber:Number = 64;
for (i=1; i<=imagesNumber; i++) {
container.attachMovie(“image”+i,“image”+i+_mc,i);
myImage_mc = container(“image”+i+_mc);
myImage_mc._x = (i-i)*myImage_mc_width
myImage_mc._y = (Stage.height == myImage_mc.height)
}
container.onEnterFrame = function() {
this._x +=math.cos((-_root._xmouse/Stage.width) *Math.PI)*15;
if (this._x>0) {
this._x = 0;
}
if (-this._x>(this._width-Stage.width)) {
this._x = -(this._width-Stage.width);
}
}