<-- Previous || Up || Next -->

Strip Double Quotes Function
String Manipulations Class

Public Function StripDoubleQuotes( _
    ByVal vValue As Variant _
    ) As Variant

Strips surrounding double-quote characters from a string (if they exist).

Examples:
    StripDoubleQuotes("Other") = "Other"
    StripDoubleQuotes("""Other""") = "Other"
    StripDoubleQuotes("Other""") = "Other"""
    StripDoubleQuotes("""Other") = """Other"
    StripDoubleQuotes(12345) = "12345"
    StripDoubleQuotes("""Larry ""Bud"" Melman""") = "Larry ""Bud"" Melman" ' #6
See also:
    GetPossiblyQuotedField Function
    GetVBToken Function
    DoubleQuoteString Function
vValue: The string which is to be stripped of surrounding double quotes. Function returns Null if vValue is Null or cannot be fixed up to a String.

If the first and last characters of the string are double-quote characters, return the string with those characters removed; otherwise, return vValue unchanged (except that non-String arguments are fixed up to Strings).
Warning: Does not replace sequences of two double-quote characters in the string with one double quote character, as would be needed for the inverse of the DoubleQuoteString function, as in example #6.

Copyright 1996-1999 Entisoft
Entisoft Tools is a trademark of Entisoft.