Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 4
Default Line Break in Cell Number Format

I would like to format a number so that it reads as follows:

Lump Sum
$5,000.00

I know that using custom formatting I can add the text, but I would like to
show the result in two lines. Is there a way to add a line break in custom
formatting?
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,696
Default Line Break in Cell Number Format

use ALTand 0010 from your number pad, not the top row of your keyboard, to
enter a line break in format cells.

"briancrosier" wrote:

I would like to format a number so that it reads as follows:

Lump Sum
$5,000.00

I know that using custom formatting I can add the text, but I would like to
show the result in two lines. Is there a way to add a line break in custom
formatting?

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,934
Default Line Break in Cell Number Format

Set the cell's Format to "Wrap Text" on the Alignment Tab and then in your
Custom Format back on the Number Tab, press Ctrl+J wherever you want the new
line to be inserted (you won't see the effect in the Custom Format field,
but it will show in the cell itself.

--
Rick (MVP - Excel)


"briancrosier" wrote in message
...
I would like to format a number so that it reads as follows:

Lump Sum
$5,000.00

I know that using custom formatting I can add the text, but I would like
to
show the result in two lines. Is there a way to add a line break in custom
formatting?


  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,934
Default Line Break in Cell Number Format

As it turns out, you can see the effect of the Ctrl+J in the Custom Format
field... use the up/down arrows to see each separate line.

--
Rick (MVP - Excel)


"Rick Rothstein" wrote in message
...
Set the cell's Format to "Wrap Text" on the Alignment Tab and then in your
Custom Format back on the Number Tab, press Ctrl+J wherever you want the
new line to be inserted (you won't see the effect in the Custom Format
field, but it will show in the cell itself.

--
Rick (MVP - Excel)


"briancrosier" wrote in message
...
I would like to format a number so that it reads as follows:

Lump Sum
$5,000.00

I know that using custom formatting I can add the text, but I would like
to
show the result in two lines. Is there a way to add a line break in
custom
formatting?



  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default Line Break in Cell Number Format

Just to add to Rick and Sean's reply...

Format|cells
On the Number tab
Custom category
"Lump Sum"(ctrl-j)$#,##0.00

Then on the Alignment tab
Uncheck Wrap text (temporarily)
Check Shrink to fit
Check Wrap text

You will have to adjust the rowheight manually.

If you don't have shrink to fit checked, you'll see #### if you shrink the
columnwidth--even when it looks like there's plenty of room for the wrapped text
to show up.

briancrosier wrote:

I would like to format a number so that it reads as follows:

Lump Sum
$5,000.00

I know that using custom formatting I can add the text, but I would like to
show the result in two lines. Is there a way to add a line break in custom
formatting?


--

Dave Peterson


  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,934
Default Line Break in Cell Number Format

Hmm! I hadn't tried shrinking the width... that's weird.

--
Rick (MVP - Excel)


"Dave Peterson" wrote in message
...
Just to add to Rick and Sean's reply...

Format|cells
On the Number tab
Custom category
"Lump Sum"(ctrl-j)$#,##0.00

Then on the Alignment tab
Uncheck Wrap text (temporarily)
Check Shrink to fit
Check Wrap text

You will have to adjust the rowheight manually.

If you don't have shrink to fit checked, you'll see #### if you shrink the
columnwidth--even when it looks like there's plenty of room for the
wrapped text
to show up.

briancrosier wrote:

I would like to format a number so that it reads as follows:

Lump Sum
$5,000.00

I know that using custom formatting I can add the text, but I would like
to
show the result in two lines. Is there a way to add a line break in
custom
formatting?


--

Dave Peterson


  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,934
Default Line Break in Cell Number Format

Never mind... I see why. Excel calculates the width of the text as if there
were no Line Feed in it (well, almost as there seems to be an extra space or
two being counted as well)... if the Column Width is set less that this
value, Excel thinks text no longer fits. I'm surprised it does this as there
are API functions available which correctly measure the width of text
containing Line Feeds... you would think since Microsoft wrote those API
functions, it would have used them in its other products (such as Excel
maybe<g).

--
Rick (MVP - Excel)


"Rick Rothstein" wrote in message
...
Hmm! I hadn't tried shrinking the width... that's weird.

--
Rick (MVP - Excel)


"Dave Peterson" wrote in message
...
Just to add to Rick and Sean's reply...

Format|cells
On the Number tab
Custom category
"Lump Sum"(ctrl-j)$#,##0.00

Then on the Alignment tab
Uncheck Wrap text (temporarily)
Check Shrink to fit
Check Wrap text

You will have to adjust the rowheight manually.

If you don't have shrink to fit checked, you'll see #### if you shrink
the
columnwidth--even when it looks like there's plenty of room for the
wrapped text
to show up.

briancrosier wrote:

I would like to format a number so that it reads as follows:

Lump Sum
$5,000.00

I know that using custom formatting I can add the text, but I would like
to
show the result in two lines. Is there a way to add a line break in
custom
formatting?


--

Dave Peterson



  #8   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default Line Break in Cell Number Format

They're smart enough to do it with plain old text, but not through a custom
number format.



Rick Rothstein wrote:

Never mind... I see why. Excel calculates the width of the text as if there
were no Line Feed in it (well, almost as there seems to be an extra space or
two being counted as well)... if the Column Width is set less that this
value, Excel thinks text no longer fits. I'm surprised it does this as there
are API functions available which correctly measure the width of text
containing Line Feeds... you would think since Microsoft wrote those API
functions, it would have used them in its other products (such as Excel
maybe<g).

--
Rick (MVP - Excel)

"Rick Rothstein" wrote in message
...
Hmm! I hadn't tried shrinking the width... that's weird.

--
Rick (MVP - Excel)


"Dave Peterson" wrote in message
...
Just to add to Rick and Sean's reply...

Format|cells
On the Number tab
Custom category
"Lump Sum"(ctrl-j)$#,##0.00

Then on the Alignment tab
Uncheck Wrap text (temporarily)
Check Shrink to fit
Check Wrap text

You will have to adjust the rowheight manually.

If you don't have shrink to fit checked, you'll see #### if you shrink
the
columnwidth--even when it looks like there's plenty of room for the
wrapped text
to show up.

briancrosier wrote:

I would like to format a number so that it reads as follows:

Lump Sum
$5,000.00

I know that using custom formatting I can add the text, but I would like
to
show the result in two lines. Is there a way to add a line break in
custom
formatting?

--

Dave Peterson



--

Dave Peterson
  #9   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,696
Default Line Break in Cell Number Format

I'd say we all learned something new on this one. Hope our original poster
did as well! :-)

"Dave Peterson" wrote:

They're smart enough to do it with plain old text, but not through a custom
number format.



Rick Rothstein wrote:

Never mind... I see why. Excel calculates the width of the text as if there
were no Line Feed in it (well, almost as there seems to be an extra space or
two being counted as well)... if the Column Width is set less that this
value, Excel thinks text no longer fits. I'm surprised it does this as there
are API functions available which correctly measure the width of text
containing Line Feeds... you would think since Microsoft wrote those API
functions, it would have used them in its other products (such as Excel
maybe<g).

--
Rick (MVP - Excel)

"Rick Rothstein" wrote in message
...
Hmm! I hadn't tried shrinking the width... that's weird.

--
Rick (MVP - Excel)


"Dave Peterson" wrote in message
...
Just to add to Rick and Sean's reply...

Format|cells
On the Number tab
Custom category
"Lump Sum"(ctrl-j)$#,##0.00

Then on the Alignment tab
Uncheck Wrap text (temporarily)
Check Shrink to fit
Check Wrap text

You will have to adjust the rowheight manually.

If you don't have shrink to fit checked, you'll see #### if you shrink
the
columnwidth--even when it looks like there's plenty of room for the
wrapped text
to show up.

briancrosier wrote:

I would like to format a number so that it reads as follows:

Lump Sum
$5,000.00

I know that using custom formatting I can add the text, but I would like
to
show the result in two lines. Is there a way to add a line break in
custom
formatting?

--

Dave Peterson


--

Dave Peterson

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Break cell into multiple lines by line break Chia Excel Discussion (Misc queries) 1 August 20th 06 06:37 AM
How do I enter a line break within a cell? Striving for efficiency Excel Discussion (Misc queries) 4 November 17th 05 08:10 PM
Manual line break in cell GKW in GA Excel Discussion (Misc queries) 1 November 6th 05 05:28 AM
Remove line break within cell Tonya Excel Discussion (Misc queries) 3 July 6th 05 08:41 PM
line break in a cell luvgreen Excel Worksheet Functions 2 June 14th 05 06:48 PM


All times are GMT +1. The time now is 04:24 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"