Exception ‘open failed: EACCES (Permission denied)’ on Android

I am getting open failed: EACCES (Permission denied) on the line OutputStream myOutput = new FileOutputStream(outFileName); I checked the root, and I tried android.permission.WRITE_EXTERNAL_STORAGE. How can I fix this problem? try { InputStream myInput; myInput = getAssets().open(“XXX.db”); // Path to the just created empty db String outFileName = “/data/data/XX/databases/” + “XXX.db”; // Open the empty … Read more