Text within Text

Ampleford

Active Member
Joined
Mar 26, 2002
Messages
380
I'm writing some text which is conditional on a set of values. This text is then shown in the form of a message box to the user. I'd like to be able to add quotes within the text, but the system doesn't like it.

eg

=if(A1=1,"That's good","That's bad, please click on "OK" and continue")

in that I'd like the OK in quote marks.....


how do I do that ?
 

Excel Facts

Control Word Wrap
Press Alt+Enter to move to a new row in a cell. Lets you control where the words wrap.
Put this instead....

=if(A1=1,"That's good","That's bad, please click on ""OK"" and continue")
 
Upvote 0
Within your formula in Excel you would write it as:

=if(A1=1,"That's good","That's bad, please click on " & CHAR(34) & "OK" & CHAR(34) & " and continue")

Best regards

Richard
 
Upvote 0

Forum statistics

Threads
1,203,094
Messages
6,053,501
Members
444,667
Latest member
KWR21

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top