adding escape characters to a VB string
Visual Basic
2
Posts
2
Posters
0
Views
1
Watching
-
I need to add escape characters to a VB string but I get errors. The string needs a double quote, and an asterisk ie. "this is the string \" \*" Problem is, this isn't working...something about a type mis-match. Any ideas?
To do double quotes, you have to use two of them to escape it:
Dim stringWithDoubleQuotes As String = "This is a ""test..."""
The contents of the string will be
This is a "test..."
A guide to posting questions on CodeProject[^]
Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
2006, 2007