How to read files under asset folder in android?
deepak - Sun Feb 19 2012 20:59:02 GMT-0500 (EST)
How do you read the files kept under the asset folder in Android?
How do you read the files kept under the asset folder in Android?
deepak - Sun Feb 19 2012 20:59:49 GMT-0500 (EST)
Answer is we can use Asset Manager
<p>Answer is we can use Asset Manager</p>
deepak - Sun Feb 19 2012 21:00:37 GMT-0500 (EST)
Steps
1) Get all the assets using AssetManager
(Under activity you have access to the get assests method)
AssetManger assets = getAssests();
2) Once you get the assets, we can look up or
open the file using the file name
InputStream is = assets.open(filename);
Once you have the ionputstream, you can read
the content in what ever way we need.