PDA

View Full Version : Escape Characters: Visual Basic


BoD][eZ
June 9th, 2004, 08:27 PM
I am writing an html interpreter of sorts and i need to output a quotation mark to file. How can i put a quotation in a string?

Dim string as String

string = "I want to put "quotes" liek that inside a string"

jdc2000
June 10th, 2004, 01:01 AM
Dim string as String

string = "I want to put " & Chr$(34) & "quotes" & Chr$(34) & " like that inside a string"

BoD][eZ
June 10th, 2004, 01:03 AM
Will it output to file correctly? IF so thanks alot man!

jdc2000
June 10th, 2004, 07:23 PM
Yes, it will output to a file correctly. However, you will need to use a Line Input statement or other method to read it back in again correctly.