Assigning x,y positions to dynamically attached clips question

As you can see I am attempting to assign x,y positions to clips that are being “attached.” I would be greatly appreciative if someone could tell me what am I doing wrong here. TIA.

var clipArray = new Array();
clipArray = [189, 275, 361]; // x positions

for (var i:Number = 1; i < 4; i++) {
this.attachMovie(“clip”+i,“butt_”+i,i,{_x: [clipArray(i-1)], _y: 142});
}

[QUOTE=wolcotter;2351052]As you can see I am attempting to assign x,y positions to clips that are being “attached.” I would be greatly appreciative if someone could tell me what am I doing wrong here. TIA.

var clipArray = new Array();
clipArray = [189, 275, 361]; // x positions

for (var i:Number = 1; i < 4; i++) {
this.attachMovie(“clip”+i,“butt_”+i,i,{_x: [clipArray(i-1)], _y: 142});
}[/QUOTE]

try:
_x:clipArray[i-1]

Thanks for the reply creatify. Unfortunately it didn’t work for me. Maybe I could get you to have a look? (See attached file). Again, I appreciate the help more than you know.

By the way, here is the edited version that isn’t working for me…

var clipArray = new Array();
clipArray = [189, 275, 361];

for (var i:Number = 1; i < 4; i++) {
this.attachMovie(“clip”+i,“clip_”+i,i,{_x:clipArray[i-1], _y:142});
}

for (var i:Number = 1; i < 4; i++) {
this.attachMovie(“btn”+i,“btn_”+i,i,{_x:clipArray[i-1], _y:289});
}

Figured it out. Again, thanks for the help.