Award-winning PDF software
Video instructions and help with filling out and completing Fill Form 8815 Filers

Instructions and Help about Fill Form 8815 Filers
What is going on guys welcome to your 81st Jeff torial and we are finally going to learn how to read stuff from a file so as you can already see I created this Chinese dot txt file and I added three more records to it so the first one is Bucky the second one is the ID number and then a name ID number name ID number name so it has four records and a record is pretty much um a row of data so now let's go ahead and figure out all right we learned how to open the file we learned how to write this stuff on this file but we don't know how to access it from a Java program so that's what I'm going to be teaching you today and the thing I didn't tell you is before we use scanner that scanner object to read from our keyboard using system in but we can actually use scanner to read from a file as well so let's go ahead and first make a private scanner variable so I'm going to name mine scan or X the cursor out of the way and now let's go ahead and just make a method to open the file first so public void open file and let's go ahead and put try to open the file so we're going to set X and again here's where we're going to put a new scanner and instead of putting a system in here which would be the keyboard just put new file and put that Chinese dot text I spell it right yep and now instead of reading from your keyboard it's actually going to read from this Chinese text file right here so that's a neat little trick that you...