Let's start with a look at a standard bit of data.
![](http://1.bp.blogspot.com/_i9xWjDR4D-E/SlMpovAdyvI/AAAAAAAAE1g/vQq2CAOq50Q/s400/20090707a.jpg)
We could just repeat the descriptive header by selecting cell A1 and copying it down to the next three rows. But it then starts to become less clear because there is too much confusing text.
So instead we'll merge cells A1 to A4 together as a single cell. In Excel a range of cells is written using the syntax A1:A4 - the colon means "through to".
![](http://1.bp.blogspot.com/_i9xWjDR4D-E/SlMqnR32oCI/AAAAAAAAE1o/-45tQRRR_us/s400/20090707b.jpg)
Then we select the Merge & Center whilst tutting slightly at the American spelling and hey presto, the four cells become one whilst at the same time the text has been centred in the horizontal plane. The text though has moved to the bottom of the new cell, to the spot previously occupied by cell A4.
This is because Merge and Center (tut!) is more often used to merge cells next to each other horizontally - grouping a number of column headings for instance.
We can do a couple of things now to format that and they include centring (darn it - the American spelling would look better there...) the text vertically and twizzing it round (Lancashire/technical term for aligning it vertically).
![](http://3.bp.blogspot.com/_i9xWjDR4D-E/SlMtSR8cW8I/AAAAAAAAE1w/FHGYrVxFtls/s400/20090707c.jpg)
Now select Format Cells.
![](http://3.bp.blogspot.com/_i9xWjDR4D-E/SlMuPhrHqOI/AAAAAAAAE14/mOE_SsjrXqs/s400/20090707d.jpg)
We can alter the text alignment to centre the text both horizontally and vertically (pointy hand 2) and we can twiz (or is it twizz?) the text (pointy hand 3).
Having clicked the Ok button and resized the cell by double-clicking the right cell wall to get the best fit the result is as shown below.
![](http://3.bp.blogspot.com/_i9xWjDR4D-E/SlMxMEZR48I/AAAAAAAAE2I/BmlQJ8uAp3M/s400/20090707e.jpg)
That's one way of doing it. Here's the other - which may appear simpler, but may not meet your needs. It's always good to have an alternative!
If whilst typing the names of the team members we used the ALT-Enter key combination we can force cell B1 to accept multiple lines within the single cell.
So we type John Tharmy then hold down the ALT key and whilst it's held down, tap the Enter key. Now without moving from the cell type Sally Vaite and use ALT-Enter again until we read the last name. Now tap the Enter alone as you would normally do and the list of names each occupy a line within the single cell.
![](http://2.bp.blogspot.com/_i9xWjDR4D-E/SlMw8Hv8ThI/AAAAAAAAE2A/6QICIljwGT4/s400/20090707f.jpg)
0 Komentar untuk "Excel: Merge Cells and Multiple Lines in Cells"