Compressing textfiles, but still read them

  • Thread starter Thread starter Jarry
  • Start date Start date
J

Jarry

I am a bit new to VB, and I have set up a program which loads a large
text file. The text file (.txt) has a file size of around 6 megabytes.
This is the figure I would like to rreduce. I have limited space on a
server, and this is a considerable chunk. anyhow, is there a file
extension which would reduce the .txt file size down, but that could
still be read by a stream reader. Thanks, Jarry
 
Immediate workaround:

Where is this file stored? If it is on a Windows NTFS drive, compress the
directory it's in using the directory property pages. Text files are highly
compressable. Doing it this way hides the compression from your
application.

Better Solution:

Add a large data drive to the server and move the file shares to it. This
has the benefit of protecting your data files in the case you have to
reformat the system disk.

Mike Ober.
 
I am a bit new to VB, and I have set up a program which loads a large
text file. The text file (.txt) has a file size of around 6 megabytes.
This is the figure I would like to rreduce. I have limited space on a
server, and this is a considerable chunk. anyhow, is there a file
extension which would reduce the .txt file size down, but that could
still be read by a stream reader. Thanks, Jarry


Zip your files - when you need to read the files, unzip the files to a
memorystream rather than an file/disk stream : )

http://www.icsharpcode.net/OpenSource/SharpZipLib
 
Back
Top