|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
special character inside a stringFind the ascii char and use chr(charNo)
for example return is chr(13) and line feed is chr(10) (i think). I don't know what " is off the top of my head but it should be east enough to find out :) Show quoteHide quote "newbie" <new***@discussions.microsoft.com> wrote in message news:6CEFD285-E5C5-4D7E-BD4A-3E3C8A61AA72@microsoft.com... > Hi > How do i put a special character like " in a string? newbie wrote:
> Hi ' Use "" to put a " in a string literal:> How do i put a special character like " in a string? Dim s As String = "This string contains a quote mark "" <-- there it is" ' Or you might prefer: Dim t As String = "This string contains a quote mark " & Chr(34) & " <-- there it is" -- Larry Lard Replies to group please Newbie,
With a double " """" is one " This is the only exception for the rest just the character. I hope this helps, Cor >How do i put a special character like " in a string? You double up the quote, so the stringfoo "bar" is written as "foo ""bar""" Any other special characters you need? Mattias -- Mattias Sjögren [MVP] mattias @ mvps.org http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com Please reply only to the newsgroup. "newbie" <new***@discussions.microsoft.com> schrieb: Encode each double quote character with two consecutive double quote > How do i put a special character like " in a string? characters: \\\ MsgBox("He said: ""Hello World!""") /// -- M S Herfried K. Wagner M V P <URL:http://dotnet.mvps.org/> V B <URL:http://classicvb.org/petition/> instr(string1,"""")
Show quoteHide quote "newbie" <new***@discussions.microsoft.com> wrote in message news:6CEFD285-E5C5-4D7E-BD4A-3E3C8A61AA72@microsoft.com... > Hi > How do i put a special character like " in a string?
Loop ?
How to update an application Binding an Array to a Combo Box SqlDataReader accessed only by field ordinals? Singleton Pattern for Database Access --- Leave Open or Close Connection Finding Version of All Asemblies Required by Application "Add Reference" hosed--doesn't display the dialog in VS.NET PDF to Picturebox repainting problem datagrid woes |
|||||||||||||||||||||||