Aller au contenu
View in the app

A better way to browse. Learn more.

Forum de Frandroid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Base SQLite sur sdcard en android 2.1 : possible ?

Featured Replies

Posté(e)

Je m'arrache les cheveux sur le problème suivant :

try
{
File sdcard = Environment.getExternalStorageDirectory();
String dbfile = sdcard.getAbsolutePath() + File.separator+ "Monrep" + File.separator + "Mabase.db";
db = SQLiteDatabase.openDatabase(dbfile, null,SQLiteDatabase.CREATE_IF_NECESSARY);
}
catch(SQLiteException exc)
{
String s=exc.getMessage();
}

J'ai une I/O error sur le openDatabase sur mon Motorola Defy en Android 2.2 (mais aucun problème sur ma tablette Acer Iconia en 3.2...)

A noter que :

1/ Le fichier est malgré tout créé avec une taille à 0

2/ j'ai bien mis la permission android.permission.WRITE_EXTERNAL_STORAGE dans le manifest

3/ Je n'utilise pas SQLiteOpenHelper précisément parce qu'il ne supporte pas les chemins externes en dessous de l'api8

4/ si la base existe sur l'appareil en Android en 2.2 je peux faire des opérations de lecture pas d'écriture

Pourquoi ce problème de lecture seule en Android 2.2 ?

Modifié par Chronogps

Archivé

Ce sujet est désormais archivé et ne peut plus recevoir de nouvelles réponses.

Account

Navigation

Rechercher

Rechercher

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.