10 Replies Latest reply on Nov 9, 2016 11:12 PM by Oriup

    JS columns distribute problem

    smoksmok

      Hi,

      sitting on this already few hours - what am I doing wrong?

      I'm trying to evenly distribute columns in a table (_tb) using folowing line, but table stays unaffected

      (I properly addressed table everything else is working just fine)

       

      _tb.columns.everyItem().redistribute(HorizontalOrVertical.HORIZONTAL);

       

       

      any idea to evenly  distribute rows/columns in a table 

      (same as Menu Command: Table->Distribute Columns Evenly)?

       

      thanks

      smok

       

      PS.

      simple workaround was :

       

      colLgth = _tb.columns.length;

      wdth = _tb.width;

      _wdth = wdth/colLgth;

      _tb.columns.everyItem().width = _wdth;

       

      but I would like to do it in one line without math and using command "redistribute"

       

      thnks

      smok