wrapping text in an if statement

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I want to force the text in an if statement to go to the
next line... I tried to place a ALT Return at the
appropriate place but I get a empty box instead of two
lines of text.

Example
IF ($A$1,"one line
two lines","line one
line two")

and I get one line0two lines

but what I want is
one line
two lines

any help??
 
try:
"one line"&char(10)&"two lines" and set the cell format to wrapped text
worked for me
 
Format the cell for wrapped text, then use the formula:

=IF($A$1,"one line"&CHAR(10)&"two lines","line one"&CHAR(10)&"line two")

HTH,
Bernie
MS Excel MVP
 
Back
Top