Cell not expending automatically.

D

Damian

Probably an easy question, how can I make the cells expand automatically to
fit the text. I have Wrap Text on but the cell does not expand.

Thanks
 
B

Bernard Liengme

A cell never expands when text is added (only when numbers are added and the
width has not been preset)
Wrap Text does nothing until you use ALT+ENTER to make a line break
best wishes
 
D

Damian

Well not the single cell but the whole row can right? I know I did it before.
When you type and its larger then the cell and you have wrap text it will
automatically expand the whole row to fit the text.
 
G

Gord Dibben

Format>Row>Autofit.

Unless you have merged cells in the range.

In that case row autofit will not work and you must add event code to
autofit.


Gord Dibben MS Excel MVP
 
M

mrao

THANK YOU Gord.   Got it working.

I tried inserting the code but had trouble with it - probably because
I've never used codes before. If anyone has tips for a beginner I
would greatly appreciate it. Also, I've used merged cells quite a bit
and discovered from this group that it's not the best thing to do. Why
is that and what are the alternatives? I just discovered this group so
thank you all in advance for taking time out to supply help.
 
G

Gord Dibben

Merged cells cause no end of problems with copying, pasting, sorting,
filtering, row fitting(as you have discovered) and many other functions.

Center across selection is one alternative.

Merged cells have their place for presentation only but if you have to be
able to manipulate data they will cause you grief.

Where did you insert the code? It must be pasted into the sheet module as
described.

Your cells must be set to wrap text and rows set to autofit prior to adding
the code and entering data in merged cells.


Gord
 
M

mrao

Mergedcellscause no end of problems with copying, pasting, sorting,
filtering, row fitting(as you have discovered) and many other functions.

Center across selection is one alternative.

Mergedcellshave their place for presentation only but if you have to be
able to manipulate data they will cause you grief.

Where did you insert the code?  It must be pasted into the sheet moduleas
described.

Yourcellsmust be set to wrap text and rows set to autofit prior to adding
the code and entering data inmergedcells.

Gord





- Show quoted text -

Gord,

I got it working. It took me some time because I never worked with
code before. Thanks so much for the help.
 

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