Split word table into 2 columns

Dear Experts

In word, using VBA, I need to split the contents of a table into two columns and repopulate.

The table has a header row "Company" and may list anything from 1 to 100 companies in the proceeding rows (These are already sorted into alphabetical order). Both columns need to have the Company header title in them.

So the logic for 10 companies listed would be...

There are 11 rows (10 + the header) - this would be split into 2 columns of 6 rows (5 companies + the header in each)

If there is an odd number of companies listed (say 9) then the second column would have a blank cell at the end so the number rows would be 5 & 5 (column 1 = header row + 5 companies, column 2 = header row + 4 companies + blank cell)

I'm thinking the easiest way to do this is to create a new table underneath, populate it and then delete the original table

The original table has been generated by exporting a query in MS Access to an RTF document.  If it’s easier then I’m sure I can do the count of the listed companies in Access.

Can anybody help?
Who is Participating?
FaustulusConnect With a Mentor Commented:
I wonder if a non-VBA solution might work for you. Please take a look at the attached document. There is only one table with the first row formatted to repeat at the top of each page. The document is formatted into two columns which is causing the table to split automatically. The height of the table is decided by the top and bottom margin. So, the difference as compared with what you asked for is in the length of the table in the second column which the table will not spill into until the first column is filled. Reset the margins to see the effect.

If this isn't good for you I would still look for an encoded solution based on the same principle, just setting the bottom margin programmatically. But a copy of the real table (with ficticious company data) would be required. I don't quite see how you envisage the page breaks if there are 100 comnpanies in your list, or why there should be, apparently, only 10 companies on each page. I sample is likely to prove helpful.
correlateAuthor Commented:
Perfect - was much simpler to use columns - thank you
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.