Hi,
I want to display a particular row of a text file and delete a particular row using C by having account no. as reference..
Can anyone help me in this.

Sample.Txt:

1234567890 James 24 50000
1234567891 Allen 32 46500
1234567892 Robert 41 13600
1234567893 Smith 29 49000

Thanks in advance..

Get row: you will have to sequentially read each line of the file in order to get to the row you want.

Delete row: rewrite the entire file, omitting the row to be deleted. Open two files: input file is the file that contains the row to be deleted, the second is an output file that will contain the new rows.

Get row: you will have to sequentially read each line of the file in order to get to the row you want.

Delete row: rewrite the entire file, omitting the row to be deleted. Open two files: input file is the file that contains the row to be deleted, the second is an output file that will contain the new rows.

Thank You I have gone through... :)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.