I want to see the contents of my database created in my app in the device I deploied it. I can use sqlite commands in shell and see in emulator but not in a real device.
Try this function as
copyFile(new File("data/data/
.
public void copyFile(File filesrc, File filedst)
{
try
{
FileInputStream localFileInputStream = new FileInputStream(filesrc);
FileOutputStream localFileOutputStream = new FileOutputStream(filedst);
byte[] arrayOfByte = new byte[1024];
while (true)
{
int i = localFileInputStream.read(arrayOfByte);
if (i == -1)
{
localFileOutputStream.close();
localFileInputStream.close();
break;
}
localFileOutputStream.write(arrayOfByte, 0, i);
}
}
catch (Exception localException)
{
Log.d("XXX", "ExceptioncopyFile:" + localException.getMessage(), localException);
}
}