views:

452

answers:

1

I am trying to do something but I haven't found anything on google since I don't know how to word it to get the right results.

I have a Form with 9 TextBox controls, and a PlainText file with 9 lines of text.

I want to click a button which will then add the first line of text from the text file into the first TextBox, then the second line into the second textbox, and so on... Can anybody please provide any advice on how to do so?

+8  A: 
Donut
perfect - thank you so much :) I'd completely forgotten all about StreamReader it's been so long since i've used it I always use File.ReadAllText nowadays lol
baeltazor
`File.OpenText` would be simpler, but indeed.
Marc Gravell
thank you Marc G. I haven't used OpenText before I will try it out :)
baeltazor
thanks for the edit Donut, changing mine now :)
baeltazor