Duplicate table row


dear friend,

 

i need help!

 

how duplicate in table row? try , search forum, have not got single solution. also, have place code , screenshot below:

please suggest me friends.

 

     var curdoc = app.documents[0];     var alltables = curdoc.stories.everyitem().tables.everyitem().getelements();     var ntables = alltables.length;     var testid = 0;   (var t = 0; t < ntables; t++) {       var curtable = alltables[t];       var allrows = curtable.rows;       var nrows   = allrows.length;              (var r = 0; r < nrows; r++) {         var currow = allrows[r];         var ip = currow.cells[0].insertionpoints[0];         var partframeid = ip.parenttextframes[0].id;            if (testid != 0 && testid != partframeid) {           var appliedstyle = allrows[r-1].cells.everyitem().appliedcellstyle = "tblr";         var addrow = allrows.add(locationoptions.before, allrows[r+0]);   //************************i have missing duplicate code here****************************** //************************help need******************************                        }       testid = partframeid;       }     }   

 

 

screenshot here:

ddd.png

 

thanks in advance

ks

it looks can use header option available in table menu



More discussions in InDesign Scripting


adobe

Comments

Popular posts from this blog

Illustrator CS6 Ocurrío un error E/S en el archivo.

Why is os_ViewContainer running?

Animate - problem with duplicating scripts after loop