#1
|
|||
|
|||
Inserting multi row CSV into recurring table in word
Hi. I hoping someone can help me with this as I'm at a complete loss being a naive word user.
I have a CSV file with 10 columns and up to a few thousand rows. The columns have headers and I want to import this into a word document that has a table with 20 rows (one for each header and one for the cell data). For each row of data I want to populate a new table and so on for all the rows. How would I go about this? And thank you in advance for any answers! |
#2
|
||||
|
||||
From your description, it's possible a mailmerge would be the way to go, but it's unclear whether the CSV file has headers that repeat every 20 rows and whether you just want the output to all go into the same place in the document (i.e. a new table every 20 rows, one after the other) or whether you want to create replicas of the document with the same content, except for the table data, every 20 rows.
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#3
|
|||
|
|||
Quote:
I'll try and clarify it a bit: The CSV is ten columns the first row being the header. The rest of the rows are data (mostly text). Code:
(headerA) (headerB) ... (datax1) (datay1) ... (datax2) (datay2) ... Code:
(TABLE1) (headerA) (datax1) (headerB) (datay1) ... (EOF TABLE1) (TABLE2) (headerA) (datax2) (headerB) (datay2) ... (EOF TABLE2) |
#4
|
||||
|
||||
It would be helpful if you could attach an actual CSV file with some representative data (delete anything sensitive), plus a document showing the required table structure, to a post. You can do that via the paperclip symbol on the 'Go Advanced' tab at the bottom of this screen.
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#5
|
|||
|
|||
Quote:
|
#6
|
|||
|
|||
I fixed this in the end. I wrote a script to read and convert the CSV data into a formatted RTF for importing into word. Seemed easier to do it that way than wrestle with word!
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Inserting a formula to count 30 days before and after a date in WORD table | bjh894 | Word | 9 | 05-18-2020 11:14 AM |
Rotating a multi page table in word 2011 for Mac | UncleheFTy | Word Tables | 1 | 08-17-2014 03:22 PM |
programmatically inserting hidden text into a Word 2010 table | epid011 | Word VBA | 16 | 12-30-2013 11:29 AM |
inserting a string of data into an MS Word table??? | matto | Word VBA | 0 | 07-16-2010 09:35 AM |
How do I reference a merged cell in a multi column & row table in MS Word ('03')? | jihanemo | Word Tables | 0 | 03-18-2009 08:33 AM |