Reading characters in a string.
Posted on 2001-07-10
I have a function that takes a compressed string, uncompresses it, and returns the uncompressed string. The compression is very simple. When 3 or more consecutive spaces or zeroes are encountered, they are removed and replaced with a flag (ASCII 126 for zeroes and ASCII 127 for spaces) and the binary number of spaces or zeroes. All of this works properly.
My problem is that when I create an EXE, the program takes 2 to 3 times longer to uncompress the string than just running the program through the VB IDE. Both are running the exact same code.
Any ideas on what the problem could be? I can post the code if it will help.