Skip to main content
2 de 3
se añadieron 85 caracteres en el cuerpo
Jorgesys
  • 111.1k
  • 14
  • 55
  • 134

Android Studio open failed erofs (read-only file system)

En mi aplicación obtengo el error:

open failed erofs (read-only file system)

Este es el codigo:

AssetManager am=getAssets();// If this line gives you ERROR then try AssetManager am=getActivity().getAssets();
        InputStream is=am.open("inventario.xls");
        Workbook existingWorkbook = Workbook.getWorkbook(is);
        WritableWorkbook workbookCopy = Workbook.createWorkbook(new File("inventario.xls"), existingWorkbook);
        WritableSheet sheetToEdit = workbookCopy.getSheet(0);
        WritableCell cell;
        Label l = new Label(16,0,"Cotejar");
        cell = (WritableCell) l;
        sheetToEdit.addCell(cell);
        workbookCopy.write();
        workbookCopy.close();

        FileOutputStream fo = new FileOutputStream(new File(getFilesDir(),"inventario.xls"));
        existingWorkbook.getCell("");
        fo.close();