I have a file stored in /data/data/com.sai.myproj/files/a.txt .This is the file I created and wrote data, it was stored in data/data/com.sai.myproj/files/a.txt which can be viewed using FileExplorer of DDMS. How to copy this file from there to res folder as I need to parse this file .
Can anyone help me in sorting out this issue.Thanks in Advance,开发者_开发百科
You can use adb pull
on your computer:
adb pull /data/data/com.sai.myproj/files/a.txt your-project-location/res
Adb is located in android-sdk/tools.
AFAIK an installed application cannot write to its own res folder
If you want to copy something from a device into the res folder of your project sources, you can use the adb tool, either from the command line by programmatic usage of the command line as part of a script or .bat file or using the shell exec function of your chosen language on your chosen development platform
Make sure you have the SDK fully installed and that the adb executable is in your path or reference it by its full path name (ie, make sure 'adb shell' works)
精彩评论