Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

want to read the text file and store into the list.

Posted on 2014-04-14
1
265 Views
Last Modified: 2014-05-16
Hi experts,

I have text file like this. I want to read the file and store it into a List.

Guids         TrxDate      RefNo.
2343325    11-MAY-11    2893423POIU            
2895321    15-JUN-12    2144423WERT
2663920    10-AUG-05    2123602Y6OU
2353969    19-JAN-10    75663423TER
2569921    18-FEB-09    2123423WYUX
2309821    10-MAY-13    2999999RWRX
0
Comment
Question by:Tapan Pattanaik
1 Comment
 
LVL 14

Accepted Solution

by:
frankhelk earned 500 total points
ID: 39998787
For code to read a file line by line, see i.e. here.

To separate the context of the lines themselves, you might use Split() (see here. Be sure to fix (if needed) double separator occurence (i.e. by applying Replace() repeatedly, see here) to ensure that the data is separated correctly.

Have fun :-)
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Just a quick little trick I learned recently.  Now that I'm using jQuery with abandon in my asp.net applications, I have grown tired of the following syntax:      (CODE) I suppose it just offends my sense of decency to put inline VBScript on a…
Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

808 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question