Assign text with quotes as a string

ilcaa72

Registered User.
Local time
Yesterday, 19:08
Joined
Nov 27, 2016
Messages
38
i have this string that i want to assign to a variable.

"*","*","APPLE INC","AAPL","USA" [EXTRACT]"754.889","Information technology","63","52","94","64","5.10","16.08","15.40","2.29","0.96","17.33","7","15","8.94","10.24","9.42","9.04","9.33","0.06","0.34","7","15","0.06","0.01","0.01","0.06","8.10","7.72","1.2","87.14","106.53","30.37","-78.86","67","123.59","3.08","2.62"

i have tried this but doesnt work..Anyone have a suggestion, is this possible with sooooo many quotes. Quotes cannot be removed BTW

Code:
x = [B]CHR(34) &[/B] "*","*","APPLE INC","AAPL","USA" [EXTRACT]"754.889","Information Technology","63","52","94","64","5.10","16.08","15.40","2.29","0.96","17.33","7","15","8.94","10.24","9.42","9.04","9.33","0.06","0.34","7","15","0.06","0.01","0.01","0.06","8.10","7.72","1.2","87.14","106.53","30.37","-78.86","67","123.59","3.08","2.62" [B]& CHR(34)[/B]
 
If you want a double quote in a string you need to double it. For example.

Code:
Dim strQuote as String
strQuote = "He said, ""This needs two quotes ""."

So I suggest using the VBA editor to double them up. Just press Ctrl H and replace " with "".
 

Users who are viewing this thread

Back
Top Bottom