ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Formatting text within functions (https://www.excelbanter.com/excel-worksheet-functions/159090-formatting-text-within-functions.html)

jasonr17

Formatting text within functions
 
I am interested in a function returning a simple calculation concatenated w/
text, but would like the format of the returned caculation to be a
percentage.

ie.

=concatenate(D2/E2," growth over 07") and want it to return as

135% growth over 07

instead of
1.350323 growth over 07


here is the actual function

=IF(H2<1,"need to chase",IF(AND(H21,H2<G2)=TRUE,"08' preseason under
forecast",IF(H2<D2,"08' preseason less then
07'",IF(ISERROR(H2/D2)=TRUE,"100%",CONCATENATE(H2/D2," growth over 07'")))))

Any suggestions, Thank you,




JE McGimpsey

Formatting text within functions
 
One way:

=TEXT(D2/E2, "0%") & "growth over 07"

In article ,
jasonr17 wrote:

I am interested in a function returning a simple calculation concatenated w/
text, but would like the format of the returned caculation to be a
percentage.

ie.

=concatenate(D2/E2," growth over 07") and want it to return as

135% growth over 07

instead of
1.350323 growth over 07


here is the actual function

=IF(H2<1,"need to chase",IF(AND(H21,H2<G2)=TRUE,"08' preseason under
forecast",IF(H2<D2,"08' preseason less then
07'",IF(ISERROR(H2/D2)=TRUE,"100%",CONCATENATE(H2/D2," growth over 07'")))))

Any suggestions, Thank you,


Rick Rothstein \(MVP - VB\)

Formatting text within functions
 
You can use this to do what you want...

CONCATENATE(TEXT(H2/D2,"0%")," growth over 07'")

However, for a simple concatenation like that, you can eliminate the
CONCATENATE function and just use this...

TEXT(H2/D2,"0%")&" growth over 07'"

using the ampersand symbol to join the two pieces of text.

Rick


"jasonr17" wrote in message
...
I am interested in a function returning a simple calculation concatenated
w/
text, but would like the format of the returned caculation to be a
percentage.

ie.

=concatenate(D2/E2," growth over 07") and want it to return as

135% growth over 07

instead of
1.350323 growth over 07


here is the actual function

=IF(H2<1,"need to chase",IF(AND(H21,H2<G2)=TRUE,"08' preseason under
forecast",IF(H2<D2,"08' preseason less then
07'",IF(ISERROR(H2/D2)=TRUE,"100%",CONCATENATE(H2/D2," growth over
07'")))))

Any suggestions, Thank you,





Gary''s Student

Formatting text within functions
 
=CONCATENATE(TEXT(D2/E2,"0%")," growth over 07")
--
Gary''s Student - gsnu200746


All times are GMT +1. The time now is 10:15 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com