Public Function CompressString( _ ByVal vString As Variant _ ) As Variant
CompressString("This is a test.") = Chr$(3) + Chr$(158) + Chr$(200) + Chr$(142) + Chr$(234) + Chr$(159) + Chr$(243) + Chr$(240) + Chr$(46) CompressString("ZYXWVU") = Chr$(3) + "ZYXWVU" ' #2 CompressString("ABCCCCCDE") = Chr$(2) + "AB" + Chr$(255) + Chr$(5) + "CDE" CompressString(EveryCharacter) = Chr$(1) + EveryCharacter ' #4See also:
DecompressString Function RunLengthEncode Function SqueezeString FunctionReturn: This function prefixes the result string with a single character that represents the type of compression used.
vString: The string containing the text which is to be compressed. 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.
Copyright 1996-1999 Entisoft
Entisoft Tools is a trademark of Entisoft.