|
-
Nov 8th, 2000, 02:56 PM
#1
My problem is that I have a text file thats around 6MB and its going to be getting bigger everyday, its a log file for a web server. I've tried to load it into a vb using the standard Open then line input stuff but vb either runs out of mem or hangs forever. If anyone knows code that will make it load a lot faster please post it or send me and email, [email protected]. Something like wordpad would work great, because it loads the file in like 5 seconds, any help would be appreciated, thanks.
-
Nov 8th, 2000, 03:07 PM
#2
Why don't you use the RichTextBox control? It can hold up to 2 GB.
RichTextBox1.LoadFile "C:\myfile.txt", rtfRTF 'or rtfText for regular text files
RichTextBox1.SaveFile "C:\myfile.txt", rtfRTF 'or rtfText for regular text files
..just a suggestion .
-
Nov 8th, 2000, 03:44 PM
#3
is there a way to show the progress of the file being loaded in the rich text box?
-
Nov 8th, 2000, 05:21 PM
#4
Frenzied Member
I think you can open the file binary... then get it in chunks and then calculate the loaded part and the filesize to show the progress.
Use the RichTextBox as Matthew said, but open the file for binary.
See kedaman's site for more info about Files in VB
http://www.kedaman.com < hey keda, you gotta pay me for all this advertising!
Jop - validweb.nl
Alcohol doesn't solve any problems, but then again, neither does milk.
-
Nov 8th, 2000, 08:07 PM
#5
when I open it as binary almost all the characters turn into ?'s.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|