7 Replies Latest reply on Jan 12, 2018 8:58 AM by Michel [FRIdNGE]

    Multicolumn text box to table?




      Is it possible to make a multi-column text box into a table in InDesign CC 2017? I feel I'm missing something obvious.

      Maybe there's a script to handle this? (See screenshot)

      Screen Shot 2017-05-13 at 00.13.37.png

        • 1. Re: Multicolumn text box to table?
          Cari Jansen Adobe Community Professional

          Hmmm... tricky one. The quickest way I can think of is to first create a 7 column table, then transpose this to 4 columns (swapping rows/ columns):



          1. Choose Object > Text Frame Options, and in the General tab, change Number of columns to 1. Click OK.
          2. Select all the text (Ctrl/Cmd-A) and choose Table > Convert Text to Table
          3. Set Column and Row Separator to Paragraph and Number of Columns to 7. Click OK.  (note: sadly setting the number of columns here to 4 gives a very muddled up table as it uses the text thread order, so it's better to first of all build the 7 column table based on).
          4. Select the Table and Copy the text (Ctrl/Cmd-C)
          5. Launch Microsoft Excel, and click in the top left cell and Paste (Ctrl/Cmd-V). And use the following technique to transpose the rows and columns: Transpose (rotate) data from rows to columns or vice versa - Excel
          6. You can now either Place the Excel spreadsheet as a Table, or else copy and paste the text into an empty text frame and then use Convert Text to Table (with Column set to Tab, and Row to Paragraph in the Convert Text to Table dialog box).


          If you do this a LOT, it'll indeed be good to see if someone is willing to develop a Transpose Rows/Columns script for InDesign CC (2017), which means you'd not need to jump out of InDesign into Excel to perform the transpose.  There might already be a plug-in around that includes this feature, one of the other forum support crew might be able to supply a link for that one.

          1 person found this helpful
          • 2. Re: Multicolumn text box to table?
            MW Design Level 5

            It is an interesting problem.


            One can export to PDF, in Acrobat, Save as Other, save as a Word document or an Excel spreadsheet, open and copy the text and paste into a frame in ID and convert text to table as well.

            • 3. Re: Multicolumn text box to table?
              Laubender Adobe Community Professional & MVP


              it's relative easy to do this by script.


              Here the steps in the UI:


              1. Add a textframe with a table of four columns.
              The number of rows will be the maximum number of paragraphs you have in one of your text frame columns.

              2. Select the text in column 1 of your 4-column text frame.

              3. Copy to the clipboard.

              4. Select cell 1 of column 1 of your table.

              5. Paste.


              Now the cells of column 1 of your table contain one paragraph each.


              Repeat with columns 2 to 4.


              That will preserve all the formatting details of your text and removes the paragraph signs at the end of the pasted paragraphs.



              • 4. Re: Multicolumn text box to table?
                Erica Gamet Adobe Community Professional

                Yes, I think Uwe has the simplest solution: Copy and paste each column of text into a column of a table. Sometimes simple is the best...unless you have hundreds to do.

                • 5. Re: Multicolumn text box to table?
                  Michel [FRIdNGE] Level 1

                  Hi all,


                  Imho, the simplest way is to click "OK"!


                  Using this "light version" script (without UI) [link to download below], the user will need to previously create (or modify style names):

                  • a table style, named "TestTable"

                  • "Red" and "Blue" cell styles, associated to "Red" and "Blue" para styles

                  • "Table_Anchoring" para style.


                  When done, just select the text of the future table [without taking in account in the selection the last carriage-return] …

                  and play the script. Last screenshot, after 4 clicks!


                  [No need to add blank paras for the column last cells if empty]


                  Capture d’écran 2018-01-12 à 14.22.41.png


                  Capture d’écran 2018-01-12 à 14.55.51.png


                  Capture d’écran 2018-01-12 à 14.23.30.png


                  The "Pro" version has an UI to choose several kinds of settings (para styles and Table style, table columns width adjustment (on contents), and especially various "batch treatments" (doc, story, text selection, condition)!, useful if hundreds of tables to be treated!

                  In this last case, the op will just need one click!



                  Greg, from FRIdNGE


                  Link:  Dropbox - TableBuilder_FRIdNGE.jsxbin

                  • 6. Re: Multicolumn text box to table?
                    Laubender Adobe Community Professional & MVP

                    Hi Greg,

                    the original poster never came back to comment on our suggestions.
                    So we really don't know what the exact specifications were and how flexible or unflexible a solution could be.

                    We only see one use case in the inital post.


                    Don't get me wrong: I appreciate that you make that script available for download.


                    But preparing paragraph styles and applying them to text ranges before running that script?

                    Don't think, that this is very sufficient in this case. If you have to do that you also could add one step after selecting a text range (one by column) and copy the selected text over to a table.

                    But let's see if the OP comes back eventually and comments on this…



                    • 7. Re: Multicolumn text box to table?
                      Michel [FRIdNGE] Level 1

                      Hi Uwe,


                      No problem of course! …


                      Copy/Paste could just be finally a little boring for the op with some thousands of columns! …



                      Greg, from FRIdNGE