Hello all. I am very new to VB.Net and am currently learning the basics and mechanics of how the software functions, my past was mainly with Matlab, so naming variables and such is quite different to me now.

My question is this: How can I read data from a .csv file I have opened into a variable for later use (i.e. plotting with zedgraph)? My csv file contains 100+ columns and 12000+ rows of data, with each column a different variable.

I've searched around a ton on this subject, and combined many methods I found on the net to my project but none actually do what I am required to do.

So, I apologize in advance if this seems really fundamental! Any help would be much appreciated!!!!

7 Years
Discussion Span
Last Post by G_Waddell


There are a couple of ways to do this one is to read each line in using filesystemObject or system.io.

Another is to open an excel object and read the csv file in you can then interact with it as if it were a database and even query it. My main concern would be the amount of data you have, I'm not sure if Excel will be able to handle it.


G Waddell, thanks for your reply. I actually used StreamReader then read line by line and then used Split to cut all of the data up.

Now my problem is getting the data into an array.

Thanks again for your help!

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.