Function Co Decs Class

DecompressString

Decompress a string which was compressed with the CompressString functions. Uses the first character of the string to identify which text decompression algorithm to use to decompress the string.

Signature (Visual Basic / VBA)

Public Function DecompressString( _
    ByVal vString As Variant _
    ) As Variant

Code Example

    DecompressString(Chr$(3) + "ZYXWVU") = "ZYXWVU"
    DecompressString(Chr$(2) + "AB" + Chr$(255) + Chr$(5) + "CDE") = "ABCCCCCDE"
    DecompressString("Sample") = "Sample" ' #3

Parameters

Parameter Description
vString The compressed string which is to be decompressed. Function returns Null if vString is Null or cannot be fixed up to a String. Function returns an empty string if vString is an empty string. Function returns vString unchanged if its first character is not a valid identifier of one of the text compression techniques as in example #3.