|
-
Jun 29th, 2005, 08:18 PM
#1
Thread Starter
Lively Member
Text file to listview, with premature EOF...
I have a decent sized list of lines which i load to a listview using a traditional list opening code (below). All works well, but encountering certian strings which are apparently EOF markers cut things off early leaving my list half empty.
VB Code:
Open "C:\FileCodeList.txt" For Input As #1
Do While Not EOF(1)
Line Input #1, str1
If Left(str1,7)="KeepC:\" Then ListView1.ListItems.Add , , str1
Loop
Close #1
Ive read many articles on open as binary, but i cannot get any sort of list population going with that. Plus, i cannot store the entire file as a array due to its large size. From 1 to 150 MB.
Im not sure if i should somehow process the file before loading, removing or replacing all Null characters or EOF marking characters ( im not sure what they are) , or if there is a binary loop i can use to load this list successfully.
Amy help would be much appreciated. Thanks ahead of time.
Last edited by THCfog; Jun 29th, 2005 at 08:25 PM.
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
|