TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Guest User
Tech Writer
77
13.9k
read multiple csv data in c#
Jul 13 2020 2:16 AM
Hi, i have question
How to write the code for read multiple csv file in a folder and display it in console ?
For right now, i can only do read one file for example:
string path = (@"C:\ipub\root\Book1.csv");
string[] lines = System.IO.File.ReadAllLines(path);
foreach (string line in lines)
{
Console.WriteLine(line);
string[] columns = line.Split(',');
foreach (string column in columns)
{
Console.WriteLine("Kandungan : " + column);
}
}
please help me, thank you
im using visual studio 2019,c#
Reply
Answers (
2
)
How to fetch the data based on from date to to date in c# windows
Code that can check CSV file has been process or not