Word-Wrap Help?

V

Victor Delta

In a spreadsheet, I have one worksheet which contains a lot of data and
text. Another worksheet copies some of that info (using the LOOKUP function)
into a more manageable form for viewing and printing etc.

Some of the fields contain quite a bit of text and so, in the second
spreadsheet, I have formatted the cells using word-wrap so that all the text
is visible. This works well.

However, if I now add some additional text to one of the cells in the first
worksheet, the second worksheet does not automatically re-word-wrap, so the
end of the new text will be hidden. I have found that if I manually remove
the word-wrap and then reapply it, the cells adjust to show all the text.

So my question is - is there a way of making the worksheet automatically
adjust the word-wrapping when necessary?

If not, then I guess I could write a macro to do what I currently do
manually. If I do go down this path, is there a way to make a macro run
automatically when one clicks on the tab of a particular worksheet (i.e. the
second one, in this case)?

TIA

V
 
S

Sheeloo

You can sue Private Sub Worksheet_Activate()
which is executed when you click on the tab for the worksheet.
 
V

Victor Delta

Sheeloo said:
You can sue Private Sub Worksheet_Activate()
which is executed when you click on the tab for the worksheet.

Many thanks. Does just what I wanted.

V
 
V

Victor Lobo

Many thanks. Does just what I wanted.

V

Hi

This issue does not occur in Excel 2007!

For 2003 this code below seems to work. Add it in the second sheet.


Private Sub Worksheet_Calculate()
Me.Rows.AutoFit
End Sub



Thanks,
Victor
 
V

Victor Delta

Hi

This issue does not occur in Excel 2007!

For 2003 this code below seems to work. Add it in the second sheet.

Private Sub Worksheet_Calculate()
Me.Rows.AutoFit
End Sub

Thanks,
Victor
------------------------------
Victor

Many thanks,

Victor
 

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