Question on ""

  • Thread starter Thread starter Michael R. Pierotti
  • Start date Start date
M

Michael R. Pierotti

thrdReply.SMSMessage = "The keyword " + Keyword + "does not exists. Please
try again."

I want to add "" around the String Keyword and am not exaclty sure what to
do.

Thanks,
Mike


--
THIS TRANSMISSION CONTAINS PROPRIETARY AND CONFIDENTIAL INFORMATION.This
information is intended to be for the exclusive use of the individual or
entity named above. If you are not the intended recipient, be advised that
any disclosure, copying, distribution or other use of this information is
strictly prohibited. If you have received this transmission in error,
please notify us by telephone at +16717881000 or by email to (e-mail address removed)
immediately.
 
Michael R. Pierotti said:
thrdReply.SMSMessage = "The keyword " + Keyword + "does not exists. Please
try again."

I want to add "" around the String Keyword and am not exaclty sure what to
do.

Encode each double quote by two consecutive double quotation mark
characters:

\\\
.... = "The keywords """ & Keyword & """ does not exist. Please try again."
///

I suggest to use the '&' operator for concatenating strings instead of using
'+'.
 
Nope that does not work

thrdReply.SMSMessage = "The keyword "" & Keyword.toUpper & "" does not
exist. Please try again."
Gives me

The Keyword & Keyword.toUpper & does not exist. Please try again.
 
Michael,

Michael R. Pierotti said:
thrdReply.SMSMessage = "The keyword "" & Keyword.toUpper & "" does not
exist. Please try again."
Gives me

The Keyword & Keyword.toUpper & does not exist. Please try again.

I can only repeat what I said:

\\\
.... = "The keywords """ & Keyword & """ does not exist. Please try again."
///

Notice that there are actually three (!) consecutive double quotation
characters. The last one is used to terminate the first string literal
before the '&' operator.
 
Gotcha. Font on my screen is so small I missed the extra " in there :s
Thanks,
Mike
 
\\\
.... = """The keywords " & Keyword & """ does not exist. Please try again."
///

I hope this helps?

Cor
 
Back
Top