Text Wrap and Vertical Alignment

Return | See a Movie of the Process

Often due to document layout issues or for personal taste, you may wish to have Excel display several lines of text in a single cell. This may be accomplished more than one way. We will explore two ways to get two lines of text in a single cell.

Text Wrap

The Excel developer probably has had experience with word processing programs when you type a line of text and reach the right margin of the document. If you continue typing, the additional text will "wrap" to the next line and you didn't have to do anyting to make it happen. This wrapping of text is the default setting in most word processing programs. Excel doesn't make this the default setting for a cell. You have to change the setting.

As with many of the formatting features, the Text Wrap feature is found in the Format Cells wizard accessed by first selecting the cell(s) and then Format + Cells from the Menu.

When the Format Cells wizard appears, select the Alignment tab and notice the Wrap Text block at the bottom.

 

The default setting here is the Wrap Text is OFF. Place a check in the box and Text Wrap is turned on.

 

If you change your mind and want to take off the Wrap, return to this panel and click off the checkmark you previously placed. That's all there is to it!

A couple of examples might let you see how you could use the wrapping of text in a single cell.

 

In this example, cell B5 contains the same information as cell B2, only the Wrap feature has been turned on.

Also note the cell has the Center alignment selected.

This could be useful in the column heading is narrow and you can still see all of the text in a horizontal layout.

There could be some visual value in controlling the alignment of the text vertically. Let's examine how this could happen.

When data is entered into a cell, the default vertical alignment is to display the data at the bottom.

Note in the Example A (on the left), the numbers are aligned to the right and text is aligned to the left. You can control the alignment by setting the horizontal alignment to center as in Example B. If you prefer, you can change the default vertical alignment and choose between top, middle, or bottom.

Select the cell(s) whose vertical alignment you wish to change and select Format + Cells from the Menu.

The Format Cells tab should be set to the Alignment choice.

Notice you can set the horizontal alignment and the vertical alignment from this choice.

If you click on the down-arrow beside the Vertical alignment choice, you will see the options. Drag the mouse to highlight your choice.

 

When the alignment is set to your satisfaction, click on OK. This directs Excel to display the cell contents using your alignment choices.

 

 

 

This example shows numbers and text. Each of the three cells reflect horizontal centering and vertical alignment in the middle.

Even though vertical alignment is always "on" at some setting, you will not notice the alignment until the height of the cell row is sufficiently large enough to create space.

 

Return | See a Movie of the Process