How to use text wrap property for tables.

N

Nandini

I am trying to insert Excel data in word table using macro. I need the text
in tables to fit the cell size. How can I make it wrap. I tried '
tbl.Rows.WrapAroundText = True' , but it did not help.

My Excel file has around 350 rows. How can I insert pagebreaks in word macro.
 
S

Suzanne S. Barnhill

Text in Word tables wraps by default, and the row height increases
accordingly. Are you experiencing something different when you paste Excel
data into Word?
 
N

Nandini

The text in the table boxes runs beyond the cell boundary into the next cell,
if the next cell is empty. I wanted it to wrap evenif the next cell is empty.
 
S

Suzanne S. Barnhill

This does not happen in Word; text in a cell is always confined to that
cell.
 
N

Nandini

Let me try again. One more question.
How can set the width of the columns and set the text direction or
orientation using the macro?
- Thanks Nandini
 
S

Suzanne S. Barnhill

If you are trying to do this programmatically, you would be better advised
to ask in one of the word.vba NGs.
 
S

Stefan Blom

Most likely, Word decided that the long line of text was intended as
some sort of heading for several columns and therefore merged the
cells. That would create something like this:

Cell 1, row 1 with long text | Cell 3, row 1
Cell 1, row 2 | Cell 2, row 2| Cell 3, row 2

Have you tried the Split command on the Table menu?
 
S

Stefan Blom

Clarification: The combination of "long line of text" and an empty
cell causes the problem.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top