My application has a database that has to be exposed to global search.
I have the sqlite database in my res/raw dir. I am trying to copy the
database file to the databases directory in my project but it throws a
FileNotFoundException. I am guessing that this is a permissions issue.

My application is similar to the Searchable dictionary but the problem
is that since I have around 2000 records, it is taking around 15-30
seconds to populate the database. I also have to way to tell the user
that the data is loading. So I just decided to use the sqlite database
which I can copy to the databases directory of my project in the
onCreate method of my databasehelper class.[extends SqliteOpenHelper].

Now I use the same method to copy my actual application database and
it works fine. This may be because they are running in the same
process.

How can I copy my database to the databases dir or where to I need to
copy it to?. Or alternatively, is there anyway that I can let the
users know that the database is being loaded when it is loading. I
noticed that the databases are being loaded even before my search
results handler's onCreate method is called. So I cannot even display
a loading dialog from the onCreate method.

Thank you.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to