Solved

# Formula and text together in Excel

Posted on 2007-09-28
553 Views
I'm sorry but this is probably a really silly one. How can I put the results of a query into a string? So if I want a merged cell to read "(x)% of all student receive aid" where (x) is the result of cells A3/K68 how would i do that?
0
Question by:bpfsr

LVL 38

Expert Comment

Hi bpfsr,

Try this:

="(" & A3/K68  & ")% of all student receive aid"

or this:

="(" &TEXT( A3/K68*100,"#.##")  & ")% of all student receive aid"

Jim
0

LVL 17

Expert Comment

bpfsr:

You would use the TEXT function to format your calculation and then concatenate it to the text by using the ampersand.

=TEXT(A3/K68,"(0)%")&" of all student receive aid"

Kindest Regards,

Jaes
0

LVL 17

Expert Comment

Jim:

Hey there man!  Nice to see you around again!  'Course I'm just back myself, so perhaps you've been here all along...  ;)

Jaes
0

LVL 9

Expert Comment

Do You really need the brackets ? Try this, just a little change.

=TEXT( A3/B68*100,"0.00")&"% of all student receive aid"

Kanwaljit
0

LVL 17

Expert Comment

Jim and Kanwaljit:

Why are you guys multiplying by 100?  If it is a true % the TEXT function will take care of the % since it formats the result.

=TEXT(A3/B68,"0%")&" of all student rerceive aid"

<grin>

Jaes
0

LVL 17

Expert Comment

Jim and Kanwaljit:

Of course...  I assume they didn't 'rerceive' the aid.  :)

=TEXT(A3/B68,"0%")&" of all student receive aid"

Jaes
0

LVL 9

Expert Comment

Hi Jaes.
You are right. I was trying to dispense with the brackets only, but seems to have overlooked % in the text function.
Kanwaljit

(But you certainly will have to pay me \$10 to continue my membership ;)
0

LVL 38

Accepted Solution

bpfsr,

And, in case you needed to do this in code, you would use the Format() function like this:

[B2].Value = Format([A3] / [K68], "0.##%") & " of all students recieve aid."

- Hey Jaes!

I'm just in and out these days.  Nice to see you back!

Jim
0

## Featured Post

Introduction This Article briefly covers methods of calculating the NPV and IRR variants in Excel as well as the limitations in calculating and interpreting IRR results. Paraphrasing Richard Shockley, author of my favourite finance reference tex…
How to quickly and accurately populate Word documents with Excel data, charts and images (including Automated Bookmark generation) David Miller (dlmille) Synopsis In this article you’ll learn how to use ExcelToWord! to copy data,charts, shapes …
Viewers will learn the basics of slicers and timelines for both PivotTables and standard Excel tables in Excel 2013.
The viewer will learn how to use the =DISCRINV command to create a discrete random variable, use this command to model a set of probabilities and outcomes in a Monte Carlo simulation, and learn how to find the standard deviation of a set of probabil…