• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 186
  • Last Modified:

Best Method to Read Files in VB.Net

Dear Experts,

We are going to write a VB.Net program which will read huge files and parse them. The file size will be between 1-4 GB. Which is the best efficient method to read such huge files in VB.Net? Any recommendation with some documentation welcomes.

Best regards.

GK
0
GurcanK
Asked:
GurcanK
  • 3
  • 2
1 Solution
 
DhaestCommented:
What exactly do you want to do with the files ?

An enumerable class to read large text files in a For Each loop
http://www.dotnet2themax.com/ShowContent.aspx?ID=4ee44d6c-79a9-466d-ab47-56bba526534f
0
 
GurcanKAuthor Commented:
We're going to parse some fields from a formatted text file and write to a database.
0
 
DhaestCommented:
Do you know where in the file the fields are that you need or do you need a field from each textline in the file ?
0
 
GurcanKAuthor Commented:
Yes, we know where the needed fields are in each line.
0
 
DhaestCommented:
If it's in each line and the files are so big, I would read them line by line, do whatever you want to do with the data and close the file.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now