Transcript
![Page 1: Android: Reading a text file all at once from res/raw](https://reader035.vdocuments.us/reader035/viewer/2022062409/56815120550346895dbf3e87/html5/thumbnails/1.jpg)
Android: Reading a text file all at once
from res/raw
1
![Page 2: Android: Reading a text file all at once from res/raw](https://reader035.vdocuments.us/reader035/viewer/2022062409/56815120550346895dbf3e87/html5/thumbnails/2.jpg)
Right click on the res folder, choose New/Folder
2
![Page 3: Android: Reading a text file all at once from res/raw](https://reader035.vdocuments.us/reader035/viewer/2022062409/56815120550346895dbf3e87/html5/thumbnails/3.jpg)
Name the new folder raw and click Finish
3
![Page 4: Android: Reading a text file all at once from res/raw](https://reader035.vdocuments.us/reader035/viewer/2022062409/56815120550346895dbf3e87/html5/thumbnails/4.jpg)
Copy the file (use naming convention: a-z0-9_.), right click on the raw folder and select paste
4
If the file is in the folder but seen in Eclipse, go to Project/Clean or restart Eclipse.
![Page 5: Android: Reading a text file all at once from res/raw](https://reader035.vdocuments.us/reader035/viewer/2022062409/56815120550346895dbf3e87/html5/thumbnails/5.jpg)
Design has a Button and a TextView to display the results
5
![Page 6: Android: Reading a text file all at once from res/raw](https://reader035.vdocuments.us/reader035/viewer/2022062409/56815120550346895dbf3e87/html5/thumbnails/6.jpg)
Code for reading text file in res/raw all at once
6
![Page 7: Android: Reading a text file all at once from res/raw](https://reader035.vdocuments.us/reader035/viewer/2022062409/56815120550346895dbf3e87/html5/thumbnails/7.jpg)
Result:
7