Grid out of duplicateMovieclip?

peepz,

i have a small piece of code within i want to build a grid. The grid will be dynamicly builded out of 4 columns (Max) and the rows are dependig of the “ap.length”. Can somebody build this within my code?:


for (var z = 0; z<ap.length; z++) 
 {        
  duplicateMovieClip(mcPhotoHolder, "mcPhotoHolder"+z, z);
  this["mcPhotoHolder"+z]._y = 136*z
}

thanks already peepz!