gauss76
02-10-2017, 07:17 AM
Hi,
I have the following problem: I have a word document with multiple paragraphs. Each paragraph has different formatting such as font size, fony type, font colour etc. I know how to copy the paragraph from Word into an Excel cell while preserving the formatting with the following commands:
Dim TARGET_File As Excel.Application
Set TARGET_File = New Excel.Application
Dim p As Paragraph
p.Range.Copy ' Copy word paragraph with all formatting
TARGET_File.Cells(6, 6).Select ' Select cell for paste
TARGET_File.ActiveSheet.Paste ' Paste word paragraph with formatting to Excel file
However, what I really want to do is loop over multiple paragraphs in word and copy all of them into a single Excel cell while keeping the Word paragraph formatting.
Any help much appreciated.
gauss76
I have the following problem: I have a word document with multiple paragraphs. Each paragraph has different formatting such as font size, fony type, font colour etc. I know how to copy the paragraph from Word into an Excel cell while preserving the formatting with the following commands:
Dim TARGET_File As Excel.Application
Set TARGET_File = New Excel.Application
Dim p As Paragraph
p.Range.Copy ' Copy word paragraph with all formatting
TARGET_File.Cells(6, 6).Select ' Select cell for paste
TARGET_File.ActiveSheet.Paste ' Paste word paragraph with formatting to Excel file
However, what I really want to do is loop over multiple paragraphs in word and copy all of them into a single Excel cell while keeping the Word paragraph formatting.
Any help much appreciated.
gauss76