Android External Storage Example
Like internal storage, we are able to save or read data from the device external memory such as sdcard. The FileInputStream and FileOutputStream classes are used to read and write data into the file.
Example of reading and writing data in the android external storage
Drag the 2 edittexts, 2 textviews and 2 buttons from the pallete, now the activity_main.xml file will like this:
Provide permission for the external storage
You need to provide the WRITE_EXTERNAL_STORAGE permission.
Let's write the code to write and read data from the android external storage.